Open In App

How to Run a Flutter App on Android Emulator?

Last Updated : 21 Apr, 2025
Comments
Improve
Suggest changes
Like Article
Like
Report

An emulator is a virtual device created to run programs/applications derived from the host system. An Android Emulator imitates an Android device and is used to run and test Android applications on your host system without requiring the presence of a physical Android device. To run your Flutter applications on an emulator is a bit of a task if you are not well-versed with Android Studio already. In this article, we will walk you through the procedure to run your Flutter app on an Android Emulator.

You can run your Flutter application on an Android emulator using three simple steps:

  • Installation 
  • Connection
  • Running 

Given below is a detailed explanation of these steps one by one.

Step by Step Implementation

1. Installing the Emulator 

Open SDK Manager: Open your Android Studio and click on the “SDK Manager” option that appears in the center of your system screen under the More Options tab.

Android_SDK


Select Tools: After clicking the SDK manager, you will be directed to the Android SDK tab. Select the “SDK Tools tab“, check the following given options and click “OK“. 

  • Android SDK Command Line Tool
  • Android SDK Platform Tool
  • Android Emulator 
  • Google USB Driver 

Your installation of the requested components will start.

Android_SDK_Tools


After the Selection, it looks more like this:

After_Selection


Finish the Installation: Press “Finish” option in the bottom right of your screen after your installations are completed .

Open Virtual Device Manager: Open the “Virtual Device Manager” in the center of the screen just below the SDK manager option.

Device_Manager


Create Virtual Device Manager: Click on the “Create Virtual Manager” provided exactly in the middle of the screen. A dialogue box for hardware selection will pop up. 

Add_new_device


Select Hardware: Select the type of Android emulator you want to use and proceed to the next page. 

New_VD


Select System Image: Select a system image to be displayed for your Android emulator, verify the configuration, and finish the setup. Your virtual device is ready to use. 

android_version


2. Creating Connection 

In VS Code

Choose Device: Open your VS Code and from the bottom right corner of your home screen, click on the Flutter Device option.

Select Device: When you click on the Flutter Device icon, a list of available devices will open up in the command palette. Select the emulator you just created.

Process the emulator: The processing for opening the emulator will start. It may take a few seconds to wait until it opens up.


In Android Studio

Select Device: Select the Device in Android Studio run the Flutter application.

Select_Device


Launched Emulator: Your Android emulator is now ready to run your Flutter application. 

Emulator


3. Running Your Application 

Start debugging: Select the “Run without debugging” option in the “Run” tab after your emulator starts.

Launching Emulator: Your selected emulator will be launched, and will present the output of your Flutter code.  

Sample Code

Given below is a Flutter code implementation and a video tutorial for the same. 

main.dart
import 'package:flutter/material.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: const Text('GeeksforGeeks'),
          backgroundColor: Colors.green,
        ),
        body: Center(
          child: ElevatedButton(
            padding: EdgeInsets.all(5),
            color: Colors.green,
            child: const Text(
              ' Hola Geeks!! ',
              style: TextStyle(color: Colors.white),
            ),
            onPressed: () {},
          ),
        ),
      ),
    );
  }
}


Below is a sample video explaining all the steps:



Next Article
Article Tags :

Similar Reads