How to setup Flutter on Windows? – Complete Guide

setup flutter on windows

Flutter is an open-source cross-platform development SDK, using it we can develop applications for Mobile, Web, and Desktop from a single codebase. Flutter is created by Google and uses dart as the language. In this tutorial, we will setup flutter for Windows.

Reasons to use Flutter :

  • Multiple Platforms, Single Codebase
  • Real Time Hot Reload
  • User Friendly Language (Dart)
  • Helpful Community

Setup

1. System Requirements:

For flutter installation ensure that your system meets these basic needs:

  1. OS: Windows 7 or above.
  2. Storage: Atleast, 4 GB of storage is required in order to setup flutter.
  3. RAM: Atleast, 4GB (8GB or more advisable).
2. Files Required:
  • Flutter SDK: Download the latest stable version of Flutter SDK from here.
Official Flutter website to download SDK.
Flutter SDK Releases
  • Android Studio: Download the latest Android Studio from here. Android Studio is needed to download the Android SDK and Command Line Tools via the SDK manager. You can also create emulators using it easily, more on that here.
Official Android Studio website to download Android Studio.
Download Latest Android Studio
  • Visual Studio Code: You can download the latest VS code from here. It’s an editor like Android Studio but uses less resources thus more preferred.
3. Setting up the software:
  • Flutter SDK:
  1. Extract the resources from the zip.
  2. Place the files under the C directory as C\flutter or C\Users\{YourUserName}\flutter. This path will be required on a later step while setting environment varibles so copy it or note it beforehand.
Place the SDK in the C:\ drive.
Flutter SDK Path
NOTE: Don't place the Flutter SDK under any privileged folder. eg: C:\Program Files\
  • Android Studio: (internet connection needed)
  1. Run the setup of Android Studio.
  2. Download the Android SDK and the Virtual Device as well for using the emulator.
Screenshot showing the Android Components installation.
Setting up SDK components
  1. Then open Android Studio and open the SDK manager.
Where to find the SDK manager
Open SDK manager
  1. Go to the SDK Tools tab and download the SDK Command Line Tools.
Download the latest Command Line Tools.
Download the Selected Option
  • Visual Studio Code: Install the executable of VS Code and download the following plugin.
Download the latest flutter extension in VS Code under the extensions tab.
Install The Flutter Plugin for VS Code

You might also be interested in:

4. Setting up Environment Variables
  1. Go to the directory where you pasted the Flutter SDK and copy the path of the bin folder. eg: C:\flutter\bin
  2. Search Environment Variables on the start search menu and open the first result.
Search Environment Variable in Windows Search.
Open, Edit Environment Variables
  1. This will open the following page, under the system variables in double-click on the path.
Create a new Environment Variable under the system variables.
Create a new System Variable
  1. Create a new environment variable and paste the path of the Flutter SDK.
Create a new path and Enter the path where you kept the Flutter SDK.
Create a new path and enter the path of the Flutter SDK \bin folder.
  1. Save the variables and open the command prompt and run the following command and you will see the following output.
flutter doctor
Run flutter doctor to check if any issue exists.
Run flutter doctor
  1. Run the following command to fix the error of android licenses:
flutter doctor --android-licenses
  • You will see a couple of these, press ‘y’ and accept all.
Accept? (y/N):
  1. After that you re-run the flutter doctor command and you will see the following output showing that everything is fine, and kudos you can now start building your apps with Flutter.
After accepting the licenses everything seems fine and working.
All issues resolved

Next, you must take a look at these topics:

Leave a Reply

Your email address will not be published.

Next Post
Validate ImageURL in Flutter

How to check if Image URL is valid in Flutter?

Related Posts