How to Set Up Your Flutter Development Environment (Windows & macOS)

If you’re getting started with Flutter, the first step is setting up your development environment properly. This guide will walk you through installing the Flutter SDK on Windows and macOS so you can start building amazing apps in no time!

By the end of this guide, you’ll have Flutter installed and ready to create your first Flutter app. Let’s dive in!

System Requirements

Before installing Flutter, make sure your system meets these minimum requirements:

  • Operating System: Windows 10 or later (64-bit)
  • Disk Space: At least 2.5 GB of free space (excluding IDE/tools)
  • RAM: Minimum 4 GB (8 GB recommended for better performance)
  • PowerShell: Version 5.0 or later (pre-installed on Windows 10)
  • Git for Windows: Required to run Flutter commands

Step 1: Download Flutter SDK for Windows

  1. Go to the official Flutter website: 👉 https://flutter.dev/docs/get-started/install/windows
  2. Click on Download Flutter SDK (Windows).
  3. Extract the downloaded .zip file to a folder (e.g., C:\src\flutter).
    1. Do not extract Flutter into C:\Program Files (due to permission issues).

Step 2: Add Flutter to System PATH

  1. To run Flutter commands from any terminal, you need to add Flutter to your system PATH:

    1. Open Start Menu and search for “Environment Variables”.
    2. Click on “Edit the system environment variables”.
    3. In the System Properties window, click on “Environment Variables”.
    4. Under System Variables, find and select Path, then click Edit.
    5. Click New and add the following path: C:\src\flutter\bin
    6. Click OK to save and close the windows.

Step 3: Verify Flutter Installation

Now, open Command Prompt (CMD) or PowerShell and type:

				
					flutter doctor
				
			

It will check for any missing dependencies and display installation status if everything is set up correctly.

Installing Flutter SDK on macOS

If you’re a Mac user, follow these steps to install Flutter and set up your development environment.

System Requirements for macOS

Operating System: macOS 10.14 or later
Disk Space: At least 2.8 GB of free space
Xcode: Required for iOS development (Mac App Store)
Homebrew: Recommended for installing dependencies

Step 1: Install Homebrew (If Not Installed)

Open Terminal and run the following command:

				
					/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

				
			

Step 2: Install Flutter SDK on macOS

  1. Download the latest Flutter SDK (macOS) from:
    👉 https://flutter.dev/docs/get-started/install/macos
  2. Extract the downloaded .zip file to a folder (e.g., ~/development/flutter).
  3. Open Terminal and run the following command to add Flutter to PATH:
				
					export PATH="$PATH:`pwd`/flutter/bin
				
			

To make this change permanent, add the above line to your ~/.zshrc or ~/.bash_profile file.

Step 3: Install Xcode & Command Line Tools

For iOS app development, you need Xcode:

				
					xcode-select --install
				
			

Then, accept the Xcode license:

				
					sudo xcodebuild -license
				
			

Step 4: Install CocoaPods (For iOS Development)

sudo gem install cocoapods

Step 5: Verify Flutter Installation

Run:

				
					flutter doctor
				
			

It will check if Flutter, Xcode, Android Studio, and other dependencies are correctly installed.

Installing Android Studio & Emulator (For Both Windows & macOS)

For Android app development, you need Android Studio and an Android Emulator.

Step 1: Download & Install Android Studio

  1. Go to Android Studio official website:
    👉 https://developer.android.com/studio
  2. Download Android Studio for your OS (Windows/macOS).
  3. Install and launch Android Studio.

Step 2: Set Up Flutter Plugin in Android Studio

  1. Open Android Studio.
  2. Go to Preferences (macOS) / Settings (Windows)Plugins.
  3. Search for Flutter and click Install.
  4. Restart Android Studio.

Step 3: Install Android Emulator

  1. Open Android Studio.
  2. Go to Preferences (macOS) / Settings (Windows)Plugins.
  3. Search for Flutter and click Install.
  4. Restart Android Studio.

Run Your First Flutter App

Now that Flutter is set up, let’s create a simple Flutter app!

Step 1: Create a New Flutter Project

Open Command Prompt (Windows) or Terminal (macOS) and run:

				
					flutter create my_first_app
				
			

Navigate to the project folder:

				
					cd my_first_app
				
			

Run the app:

				
					flutter run
				
			

Your first Flutter app should now be running on the Android Emulator or iOS Simulator 🎉!

Common Installation Issues & Fixes

❌ Flutter command not found?
✅ Make sure Flutter is added to PATH (Restart terminal after adding it).

❌ Emulator not starting?
✅ Check if Virtualization (VT-x) is enabled in BIOS (for Windows).

❌ Flutter doctor shows missing dependencies?
✅ Run flutter doctor –android-licenses and accept licenses.

Conclusion

Congratulations! 🎉 You have successfully installed Flutter SDK on Windows & macOS and created your first Flutter app.

Now, you’re ready to dive into Flutter app development and start building amazing apps! 🚀

📌 Next Step: Learn about Flutter Widgets & UI Components in the next article!

💬 Have any questions? Drop a comment below!

Leave a Reply

Your email address will not be published. Required fields are marked *