Flutter Installation Guide for Windows and Mac

Let’s learn how to setup an environment for the successful development of the Flutter application. Flutter installation is the first step to get started in the journey of Cross platform mobile application development using Flutter. In this guide, we will focus in Flutter installation for both Windows and Mac.

System requirements for Windows

For Window to install and run Flutter, we need first to meet these requirements for your development environment.

Operating SystemWindows 7 or Later Version
Disk Space400 MB (It does not include disk space for IDE/tools).
Tools1. Windows PowerShell
2. Git for Windows  2.x
SDKFlutter SDK for Windows
IDEAndroid Studio
Visual Studio

Install Git

Before starting Flutter Installation Guide, Let’s start the guide by installing Git first.

Step1: To download Git go to this Offical Website https://git-scm.com/download/win The Offical Page look Like

Offical Git Page

Step 2: Run the .exe file to complete the installation. During installation process, make sure that you have selected the recommended option.

Click on the downloaded installer file and select yes to continue. After the selecting yes the installation begins, and the screen will look like as

Click on next to continue.

Step 3 Default components are automatically selected in this step. You can also choose your required part.

Click next to continue.

Step 4 The default Git command-line options are selected automatically. You can choose your preferred choice. Click next to continue.

Step 5 The default transport backend options are selected in this step. Click next to continue.

Step 6 Select your required line ending option and click next to continue.

Step 7 Select preferred terminal emulator clicks on the next to continue.

Step 8 This is the last step that provides some extra features like system caching, credential management and symbolic link. Select the required features and click on the next option.

Step 9 The files are being extracted in this step.

Therefore, The Git installation is completed. Now you can access the Git Gui and Git Bash.

The Git Bash looks like as

Install Flutter SDK for Windows

Step 1:  To download Flutter SDK, Go to its official website, click on Get started button, you will get the following screen.

Step 2: Next, to download the latest Flutter SDK, click on the Windows icon. Here, you will find the download link for SDK.

Step 3: When your download is complete, extract the zip file and place it in the desired installation folder or location, for example, C: /Flutter.

Step 4: To run the Flutter command in regular windows console, you need to update the system path to include the flutter bin directory. The following steps are required to do this:

Step 4.1: Go to MyComputer properties -> advanced tab -> environment variables. You will get the following screen.

Step 4.2: Now, select path -> click on edit. The following screen appears.

Step 4.3: In the above window, click on New->write path of Flutter bin folder in variable value -> ok -> ok -> ok.

Step 5: Then, run the flutter doctor command. This command checks for all the requirements of Flutter app development and displays a report of the status of your Flutter installation.

$ flutter doctor  

Step 6: When you run the above command, it will analyze the system and show its report, as shown in the below image. Here, you will find the details of all missing tools, which required to run Flutter as well as the development tools that are available but not connected with the device.

Step 7: Install the Android SDK. If the flutter doctor command does not find the Android SDK tool in your system, then you need first to install the Android Studio IDE. To install Android Studio IDE, do the following steps.

Step 7.1: Download the latest Android Studio executable or zip file from the official site.

Step 7.2: When the download is complete, open the .exe file and run it. You will get the following dialog box.

Step 7.3: Follow the steps of the installation wizard. Once the installation wizard completes, you will get the following screen.

Step 7.4: In the above screen, click Next-> Finish. Once the Finish button is clicked, you need to choose the ‘Don’t import Settings option’ and click OK. It will start the Android Studio.

Step 8: Next, you need to set up an Android emulator. It is responsible for running and testing the Flutter application.

Step 8.1: To set an Android emulator, go to Android Studio > Tools > Android > AVD Manager and select Create Virtual Device. Or, go to Help->Find Action->Type Emulator in the search box. You will get the following screen.

Step 8.2: Choose your device definition and click on Next.

Step 8.3: You can then select the system image for the latest Android version and click on Next.

Step 8.4: After that, verify the all AVD configuration. If it is correct, click on Finish. The following screen appears.

Step 8.5: Lastly, click on the icon pointed into the red color rectangle. The Android emulator displayed as below screen.

Step 9: Now, install Flutter and Dart plugin for building Flutter application in Android Studio. These plugins provide a template to create a Flutter application, give an option to run and debug Flutter application in the Android Studio itself. Do the following steps to install these plugins.

Step 9.1: Open the Android Studio and then go to File->Settings->Plugins.

Step 9.2: Now, search the Flutter plugin. If found, select Flutter plugin and click install. When you click on install, it will ask you to install Dart plugin as below screen. Click yes to proceed.

Step 9.3: Restart the Android Studio.

You can use VS Code or andriod Studio as an IDE for coding

Also read: How To Create Responsive Layout In Flutter

System Requirements for macOS

For Mac OS to install and run Flutter, we need first to meet these requirements for your development environment.

Operating SystemmacOS (64-bit)
Disk Space2.8 GB (It does not include disk space for IDE/tools).
Toolsbash
curl
git 2.x
mkdir
rm
unzip
which
IDE
Xcode (Official)

For downloading Git in mac it is same process for the Window OS

Install Flutter SDK for Mac

Step 1: Download the installation bundle of the Flutter Software Development Kit for macOS. To download Flutter SDK, Go to its official website.

Step 2: After your download is complete, extract the zip file and place it in the desired installation folder or location.

Step 3: Next, to run the Flutter command, you need to update the system path to include the flutter bin directory.

$ export PATH="$PATH:`pwd`/flutter/bin"  

Step 4: Then enable the updated path in the current terminal window using the below command and then verify it also.

source ~/.bashrc  
source $HOME/.bash_profile  
echo $PATH  

Step 5: After that, run the $ flutter doctor command. This command checks for all the requirements of Flutter app development and displays a report of the status of your Flutter installation.

$ flutter doctor  

Step 6: When you run the above command, it will analyze the system and the details of all missing tools, which required to run Flutter as well as the development tools that are available but not connected with the device.

Step 7: Do Install the latest Xcode tools if reported by the Flutter doctor tool.

Step 8: If Flutter doctor tool reports you to install the latest Android Studio and SDK then do the same.

Step 9: Next, you need to set up an iOS simulator or connect an iPhone device to the system for developing an iOS application.

Step 10: Again, set up an android emulator or connect an android device to the system for developing an android application which is similar to the window os.

Step 11: FInally install Flutter and Dart plugin for building Flutter application in Android Studio. These plugins provide a template to create a Flutter application, give an option to run and debug Flutter application in the Android Studio itself.

Related Guide: Learn Flutter Version Management (FVM), The easiest Way To Manage Multiple Flutter SDK Version