Getting started with Flutter


Flutter is a open source platform to develop applications for Android and iOS. Flutter, written in C++ and use Dart programming language also developed by google. Dart syntax is similar to programming languages like Java, JavaScript, C# or Swift . Flutter allows developers to create beautiful high-quality applications for Android and iOS with a single codebase. It is similar like React Native, but does not need to use a JavaScript bridge which avoids performance issues.

Generic placeholder image

Getting Started

In this tutorial, we will setup flutter and make basic application.

Install on Windows

System requirements

Your system must meet these requirements to install and run Flutter.

Get the Flutter SDK

  1. Download latest bundle from following link
  2. Extract zip file to safe desired location.
  3. Locate to flutter_console.bat inside flutter folder and start it with double click.

Update your path

If you want to run Flutter commands from Windows prompt, you have to update your PATH environment variable.

Run flutter doctor

Run the following command to see if there are any dependencies need to install to complete the setup.

 $ flutter doctor 

This command checks your environment and displays report on terminal.

For example:

 Doctor summary (to see all details, run flutter doctor -v):                                                
[√] Flutter (Channel beta, v0.3.2, on Microsoft Windows [Version 10.0.16299.371], locale en-GB)
[!] Android toolchain - develop for Android devices (Android SDK 25.0.3)
X Android licenses not accepted.  To resolve this, run: flutter doctor --android-licenses
[√] Android Studio (version 2.3)
X Flutter plugin version 12.1 - the recommended minimum version is 16.0.0
[√] IntelliJ IDEA Community Edition (version 2018.1)
[!] Connected devices
! No devices available                                                                                                                                                                                                                      
! Doctor found issues in 2 categories.   

Once you installed missing dependencies, run the flutter doctor command again to verify setup.

Install on macOS and Linux

These links are for installing flutter on macOS and linux operating systems.

Install Flutter on macOS

Install Flutter on Linux

Android Setup

Install Android Studio

Set up your Android Device

You will need an Android device running Android 4.1(API level 16) or higher, to run and test Flutter app.

Set up the Android emulator

You can also use Android emulator to run and test Flutter app.To prepare Android emulater follow these steps:

  1. Enable VM acceleration on your machine.
  2. Launch Android Studio>Tools>Android>AVD Manager and select Create Virtual Device.
  3. Choose a device definition and select Next.
  4. Select one or more system images for the Android versions you want to emulate, and select Next. An x86 or x86_64 image is recommended.
  5. Under Emulated Performance, select Hardware - GLES 2.0 to enable hardware acceleration.
  6. Verify the AVD configuration is correct, and select Finish.
  7. In Android Virtual Device Manager, click Run in the toolbar. The emulator starts up and displays the default canvas for your selected OS version and device.
  8. Start your app by running flutter run. The connected device name is Android SDK built for , where platform is the chip family, such as x86.

Configure Editor

Flutter is supported by two plugins:

To install these:

  1. Start Android Studio.
  2. Open plugin preferences (Preferences>Plugins on macOS, File>Settings>Plugins on Windows & Linux).
  3. Select Browse repositories…, select the Flutter plug-in and click install.
  4. Click Yes when prompted to install the Dart plugin.
  5. Click Restart when prompted.
Generic placeholder image
Generic placeholder image

Hello World Flutter App

Let's build a simple Flutter Hello World app.

Create new app

  1. Select File>New Flutter Project
  2. Select Flutter application as the project type, and press Next
  3. Enter a project name (e.g. myapp), and press Next
  4. Click Finish
  5. Wait for Android Studio to install the SDK, and create the project.
Generic placeholder image

Generic placeholder image

Generic placeholder image

Run the app

  1. Click on Run>Run 'main.dart'
  2. If you does not have Android device in target selector ,select Tools>Android>AVD Manager and create one there.
  3. Click the Run icon in the toolbar.
  4. If everything works you should see your starter app on your device.
Generic placeholder image

Try a hot reload

Flutter has ability to live update running app without restarting.Just click Hot Reload button to see changes.

  1. Change the string.
  2. Do not press 'Stop' and click the Hot Reload button.

Gurjit Singh

Hey there! I'm an experienced Android developer and a geek interested in the newest technologies and trends.