Installing Flutter SDK
The Flutter SDK (Software Development Kit) is the main collection of libraries, frameworks, command-line tools, and development utilities required to build Flutter applications.
The Flutter SDK includes the Dart SDK, Flutter framework, command-line tools, testing utilities, DevTools, rendering capabilities, widgets, and APIs required for Flutter development. :contentReference[oaicite:1]{index=1}
Installing the Flutter SDK is one of the first steps in creating a Flutter development environment. After installing it, developers should configure the SDK in their system PATH, verify the installation, and configure at least one target platform such as Android, Web, iOS, Windows, macOS, or Linux.
1. What is the Flutter SDK?
Flutter SDK is a software development kit provided for creating cross-platform applications using the Flutter framework and Dart programming language.
The Flutter SDK provides:
- Dart SDK
- Flutter framework
- Flutter command-line tools
- Dart command-line tools
- Flutter widgets
- Material Design widgets
- Cupertino-style widgets
- Testing tools
- Flutter DevTools
- Build and compilation tools
- Platform integration APIs
The main command-line executable is the flutter command, which developers use to create, build, test, run, and manage Flutter projects. :contentReference[oaicite:2]{index=2}
2. Why Do We Need the Flutter SDK?
The Flutter SDK provides the tools required to convert Flutter source code into applications that can run on supported platforms.
Without the Flutter SDK, you cannot normally use commands such as:
flutter create
flutter run
flutter build
flutter test
flutter pub get
flutter doctor
Therefore, installing the Flutter SDK is a fundamental requirement for local Flutter development.
3. Prerequisites Before Installing Flutter
Before installing Flutter, prepare a suitable development environment.
Basic Requirements
- A supported Windows, macOS, or Linux development computer.
- Internet access for downloading the SDK and dependencies.
- Git and other platform-specific prerequisites where required.
- A code editor or IDE such as VS Code or Android Studio.
- Sufficient disk space for Flutter and platform SDKs.
- A target platform for running applications.
Flutter's official installation documentation provides separate setup paths for Windows, macOS, Linux, and ChromeOS. :contentReference[oaicite:3]{index=3}
4. Choosing an Installation Method
Flutter currently provides multiple ways to install the SDK. Developers can use the quick installation workflow through a supported editor such as VS Code, or use a custom/manual setup. :contentReference[oaicite:4]{index=4}
| Method |
Description |
| VS Code Quick Install |
Uses VS Code/Code OSS tooling to download and configure Flutter. |
| Manual Installation |
Download the Flutter SDK archive, extract it, configure PATH, and verify it manually. |
For learning the underlying setup process, manual installation is useful because it demonstrates how the Flutter SDK and PATH configuration work.
5. Step 1 – Download Flutter SDK
The first step is to download the appropriate Flutter SDK package for your operating system.
Flutter provides official installation instructions and an SDK archive for available releases. The Flutter documentation recommends using current stable or beta releases where appropriate. :contentReference[oaicite:5]{index=5}
General Process
- Open the official Flutter installation page.
- Select your development operating system.
- Choose the appropriate Flutter SDK.
- Download the SDK archive.
- Save it to a suitable location.
The downloaded SDK is generally distributed as an archive that must be extracted before use.
6. Step 2 – Choose a Flutter SDK Location
After downloading Flutter, choose a directory where the SDK will be stored.
Flutter's manual Windows installation documentation recommends using a development directory such as:
C:\Users\YourName\develop\flutter
It is useful to choose a location without unnecessary spaces or special characters and one that does not require administrator privileges. :contentReference[oaicite:6]{index=6}
Example Folder Structure
C:
└── Users
└── YourName
└── develop
└── flutter
7. Step 3 – Extract the Flutter SDK
After downloading the Flutter SDK archive, extract it into the selected development directory.
Example
C:\Users\YourName\develop\flutter
After extraction, the Flutter directory should contain directories and files belonging to the SDK.
Typical Structure
flutter/
│
├── bin/
├── packages/
├── dev/
├── examples/
├── engine/
├── README.md
└── LICENSE
The bin directory is particularly important because it contains the command-line tools used to execute Flutter commands.
8. Understanding the Flutter bin Directory
The Flutter SDK's bin directory contains the command-line tools used to interact with Flutter.
flutter/
└── bin/
├── flutter
├── dart
└── cache/
The exact files can vary by operating system, but the important concept is that the Flutter SDK's bin directory must be available through the system PATH for convenient command-line usage.
9. Step 4 – Add Flutter to PATH
Adding Flutter to PATH allows the operating system to find the flutter and dart commands from a terminal or command prompt.
Flutter's official documentation specifically instructs developers to add the Flutter SDK's bin directory to PATH. :contentReference[oaicite:7]{index=7}
10. Adding Flutter to PATH on Windows
Suppose Flutter is installed here:
C:\Users\YourName\develop\flutter
The directory that needs to be added to PATH is:
C:\Users\YourName\develop\flutter\bin
Windows Steps
- Open Windows Search.
- Search for Environment Variables.
- Open Edit the system environment variables.
- Open Environment Variables.
- Find the Path variable under user variables.
- Select Path and click Edit.
- Click New.
- Add the Flutter
bin directory.
- Save all changes.
- Close and reopen the terminal.
Flutter's official Windows PATH instructions use the SDK's bin directory, for example %USERPROFILE%\develop\flutter\bin. :contentReference[oaicite:8]{index=8}
Example PATH
%USERPROFILE%\develop\flutter\bin
11. Adding Flutter to PATH on macOS
On macOS, Flutter's documentation assumes the default Zsh shell for its PATH instructions.
Suppose Flutter is installed at:
$HOME/develop/flutter
Add the following to ~/.zprofile:
export PATH="$HOME/develop/flutter/bin:$PATH"
Save the file and restart terminal sessions so the updated PATH becomes available. :contentReference[oaicite:9]{index=9}
Verify
flutter --version
dart --version
12. Adding Flutter to PATH on Linux
On Linux, the Flutter SDK's bin directory should be added to the PATH for the shell being used.
Bash Example
echo 'export PATH="$HOME/develop/flutter/bin:$PATH"' >> ~/.bashrc
Restart the terminal or reload the shell configuration.
source ~/.bashrc
Verify
flutter --version
dart --version
Flutter provides shell-specific PATH instructions for Linux and other supported environments. :contentReference[oaicite:10]{index=10}
13. Step 5 – Verify Flutter Installation
After configuring PATH, open a new terminal and run:
flutter --version
If Flutter is correctly configured, the command should display Flutter and Dart version information.
Example
Flutter 3.x.x
Dart 3.x.x
DevTools x.x.x
The exact version numbers depend on the Flutter SDK release installed on your computer.
14. Verify Dart
Dart tooling is included with the Flutter SDK.
dart --version
This command confirms that the Dart command-line tool is accessible. Flutter's SDK documentation identifies both flutter and dart command-line tools as part of the SDK. :contentReference[oaicite:11]{index=11}
15. Step 6 – Run Flutter Doctor
After installing Flutter, run:
flutter doctor
For detailed diagnostic information, use:
flutter doctor -v
Flutter Doctor checks the development environment and reports configuration issues related to Flutter and available development tools.
Example
flutter doctor
Typical categories can include:
[✓] Flutter
[✓] Android toolchain
[✓] Chrome
[✓] Android Studio
[✓] VS Code
[✓] Connected device
The actual output depends on your operating system and installed tools.
16. Step 7 – Install an IDE or Code Editor
After installing Flutter, set up an editor or IDE with Flutter and Dart support.
Popular choices include:
- Visual Studio Code
- Android Studio
- IntelliJ-based IDEs
- Other supported Code OSS-based editors
Flutter's current documentation lists VS Code, Android Studio, and other supported editors as options for Flutter development. :contentReference[oaicite:12]{index=12}
17. Installing Flutter in VS Code
VS Code provides a convenient Flutter installation workflow.
General Steps
- Install VS Code.
- Open VS Code.
- Install the Flutter extension.
- Use the Flutter extension to locate or download the SDK.
- Select the Flutter SDK location if prompted.
- Allow VS Code to add Flutter to PATH when prompted.
- Restart VS Code and terminal sessions.
- Run
flutter doctor -v.
The official VS Code installation workflow includes downloading the Flutter SDK, adding the SDK to PATH, restarting the terminal/editor, and validating the installation with flutter doctor -v. :contentReference[oaicite:13]{index=13}
18. Installing Flutter with Android Studio
Android Studio can also be used as a Flutter development environment.
General Steps
- Install Android Studio.
- Install the Flutter plugin.
- Install/configure Android SDK components.
- Configure an Android emulator or physical device.
- Verify Flutter with
flutter doctor.
Android Studio is particularly useful when the primary target is Android because it provides Android development tools and emulator management.
19. Step 7 – Configure Android Development
If you want to build Flutter applications for Android, install and configure the Android development environment.
This generally includes:
- Android Studio
- Android SDK
- Android SDK Platform Tools
- Android SDK Build Tools
- Android SDK Command-Line Tools
- Android Emulator
After configuration, run:
flutter doctor
20. Accepting Android Licenses
Android development may require accepting Android SDK licenses.
Use:
flutter doctor --android-licenses
Follow the prompts displayed in the terminal.
After completing the process, run:
flutter doctor
21. Step 8 – Configure a Device
Flutter needs a target device to run your application.
You can use:
- Android Emulator
- Physical Android device
- Web browser
- iOS Simulator on macOS
- Windows desktop
- macOS desktop
- Linux desktop
Check Devices
flutter devices
22. Create an Android Emulator
If Android Studio is installed, an Android Virtual Device can be created using Device Manager.
General Process
- Open Android Studio.
- Open Device Manager.
- Create a new virtual device.
- Select a device model.
- Select an Android system image.
- Complete the configuration.
- Start the emulator.
Then verify it with:
flutter devices
23. Using a Physical Android Device
Instead of an emulator, you can use a real Android phone for testing.
General Steps
- Enable Developer Options.
- Enable USB debugging.
- Connect the phone using USB.
- Accept the debugging authorization request.
- Run
flutter devices.
flutter devices
24. Step 9 – Create Your First Flutter Project
Once Flutter is installed successfully, create a new Flutter project.
flutter create my_first_app
Move into the project:
cd my_first_app
Run the application:
flutter run
Flutter's command-line tools support creating and running applications through commands such as these. :contentReference[oaicite:14]{index=14}
25. Understanding the Flutter Project Structure
After executing flutter create, Flutter generates a project structure similar to:
my_first_app/
│
├── android/
├── ios/
├── lib/
│ └── main.dart
├── test/
├── web/
├── pubspec.yaml
├── analysis_options.yaml
└── README.md
Important Files
| File/Folder |
Purpose |
lib/ |
Main Dart source-code directory. |
main.dart |
Common entry point of the Flutter application. |
android/ |
Android-specific project files. |
ios/ |
iOS-specific project files. |
web/ |
Web-specific project files. |
test/ |
Automated tests. |
pubspec.yaml |
Project configuration and dependencies. |
26. Simple Flutter Application
import 'package:flutter/material.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(
title: const Text('My First Flutter App'),
),
body: const Center(
child: Text('Hello Flutter!'),
),
),
);
}
}
Save the file and run the application using:
flutter run
27. Step 10 – Verify the Complete Installation
A useful sequence for checking a fresh Flutter installation is:
flutter --version
dart --version
flutter doctor -v
flutter devices
flutter create test_app
cd test_app
flutter run
If these commands work and a target device is available, the core Flutter installation is ready for development.
28. Flutter PATH: Why Is It Important?
PATH tells the operating system where executable programs are located.
When Flutter's bin directory is added to PATH, commands such as the following can be executed from any terminal location:
flutter
dart
Without PATH configuration, you may have to provide the complete path to the Flutter executable every time.
29. Common PATH Problem
Problem
'flutter' is not recognized as an internal or external command
Possible Cause
The Flutter SDK's bin directory has not been added correctly to PATH, or the terminal was not restarted after changing PATH.
Solution
- Find the Flutter SDK directory.
- Locate its
bin folder.
- Add that folder to PATH.
- Close existing terminals.
- Open a new terminal.
- Run
flutter --version.
Flutter's documentation specifically recommends reopening terminal sessions after PATH changes so the new configuration is available. :contentReference[oaicite:15]{index=15}
30. Common Installation Problem: SDK in a Difficult Location
Avoid placing the Flutter SDK in a location that requires unnecessary administrator privileges or has problematic special characters/spaces.
A simple Windows location is:
C:\Users\YourName\develop\flutter
Flutter's manual installation documentation recommends a development directory that does not require elevated privileges and avoids special characters or spaces. :contentReference[oaicite:16]{index=16}
31. Common Installation Problem: Antivirus
On Windows, security software can sometimes quarantine files from a newly extracted SDK.
If important Flutter files such as the Flutter executable are missing after extraction, check the antivirus quarantine and only allow the SDK directory when you are confident that the SDK was obtained from the official Flutter source.
Flutter's manual installation documentation specifically notes that antivirus software can quarantine flutter.bat during Windows SDK extraction. :contentReference[oaicite:17]{index=17}
32. Updating Flutter
Once Flutter is installed, developers can update the SDK as new releases become available.
flutter upgrade
Before upgrading a production project, developers should review release notes and migration information when relevant because SDK updates can introduce breaking changes.
33. Checking Flutter Version
To check the installed version:
flutter --version
For more detailed information:
flutter doctor -v
34. Flutter SDK Channels
Flutter provides release channels that developers can use depending on their development needs.
For most learners and production applications, the stable channel is generally the appropriate starting point.
Check Channel
flutter channel
Switch to Stable
flutter channel stable
flutter upgrade
Always review the current Flutter release documentation before switching channels or upgrading an important project.
35. Installing Flutter for Web Development
Flutter can be used for web development without configuring a mobile emulator.
A supported browser can be used as a development target.
flutter devices
Flutter's current documentation recommends web as a convenient first target because it requires no additional platform setup beyond an appropriate browser. :contentReference[oaicite:18]{index=18}
36. Installing Flutter for Android Development
For Android development, the typical setup is:
Flutter SDK
↓
Android Studio
↓
Android SDK
↓
Android Emulator / Physical Device
↓
Flutter Application
Run the following to check the environment:
flutter doctor
37. Installing Flutter for iOS Development
Flutter iOS development requires the Apple development environment. Therefore, a Mac and Xcode are required for iOS application development.
Flutter SDK
↓
macOS
↓
Xcode
↓
iOS Simulator / iPhone
↓
Flutter Application
38. Installing Flutter for Windows Development
Flutter can also be configured for Windows desktop application development.
The required Windows desktop development tools must be installed in addition to the Flutter SDK.
Flutter SDK
↓
Windows Development Tools
↓
Windows Target
↓
Flutter Desktop Application
39. Installing Flutter for Linux Development
Linux desktop development requires Flutter together with the appropriate Linux development dependencies.
Flutter's documentation provides platform-specific prerequisite packages and setup instructions for Linux. :contentReference[oaicite:19]{index=19}
40. Flutter SDK Installation Checklist
| Task |
Check |
| Download Flutter SDK |
SDK archive downloaded from an official source |
| Extract SDK |
Flutter directory created successfully |
| Locate bin folder |
Flutter bin directory exists |
| Configure PATH |
Flutter bin added to PATH |
| Restart terminal |
New terminal session opened |
| Verify Flutter |
flutter --version |
| Verify Dart |
dart --version |
| Check environment |
flutter doctor |
| Install IDE |
VS Code or Android Studio configured |
| Configure target |
Android/Web/iOS/Desktop target available |
| Create project |
flutter create my_app |
| Run application |
flutter run |
41. Complete Flutter Installation Workflow
Step 1
Download Flutter SDK
↓
Step 2
Extract Flutter SDK
↓
Step 3
Choose SDK location
↓
Step 4
Add flutter/bin to PATH
↓
Step 5
Restart terminal
↓
Step 6
Run flutter --version
↓
Step 7
Run flutter doctor
↓
Step 8
Install/configure IDE
↓
Step 9
Configure target platform
↓
Step 10
Check flutter devices
↓
Step 11
Create Flutter project
↓
Step 12
Run Flutter application
42. Important Flutter Commands After Installation
| Command |
Purpose |
flutter --version |
Check Flutter version. |
dart --version |
Check Dart version. |
flutter doctor |
Check development environment. |
flutter doctor -v |
Show detailed diagnostic information. |
flutter devices |
List available devices. |
flutter emulators |
List configured emulators. |
flutter create app_name |
Create a Flutter application. |
flutter run |
Run the application. |
flutter pub get |
Download project dependencies. |
flutter clean |
Clean generated build files. |
flutter upgrade |
Upgrade the Flutter SDK. |
43. Practical Example – Fresh Flutter Installation
Suppose you are using Windows and want to install Flutter manually.
Step 1: Select SDK Location
C:\Users\Manish\develop\flutter
Step 2: Add PATH
C:\Users\Manish\develop\flutter\bin
Step 3: Open a New Terminal
Step 4: Check Flutter
flutter --version
Step 5: Check Environment
flutter doctor
Step 6: Check Devices
flutter devices
Step 7: Create Application
flutter create student_app
Step 8: Open Project
cd student_app
Step 9: Run Application
flutter run
At this point, the basic Flutter SDK installation and application workflow has been completed.
44. Common Interview Questions
Q1. What is Flutter SDK?
Flutter SDK is a collection of Flutter framework libraries, Dart tooling, command-line tools, testing tools, DevTools, and other components required to develop Flutter applications.
Q2. Why do we add Flutter to PATH?
Adding Flutter's bin directory to PATH allows the flutter and dart commands to be used directly from terminals and supported IDEs.
Q3. Which command checks Flutter installation?
flutter --version
Q4. Which command checks the development environment?
flutter doctor
Q5. How do you create a new Flutter project?
flutter create project_name
Q6. How do you run a Flutter application?
flutter run
Q7. What is the difference between Flutter SDK and Flutter Plugin?
The Flutter SDK contains the actual Flutter framework and command-line development tools. A Flutter plugin/extension integrates Flutter development features into an IDE or editor.
Q8. Is Dart installed separately for normal Flutter development?
The Flutter SDK includes Dart tooling, so a separate Dart SDK installation is generally not necessary for standard Flutter development. :contentReference[oaicite:20]{index=20}
45. Key Points to Remember
- Flutter SDK is the foundation of local Flutter development.
- The SDK includes Dart tooling and Flutter command-line tools.
- Download the SDK appropriate for your operating system.
- Extract Flutter into a suitable development directory.
- Add the Flutter
bin directory to PATH.
- Restart terminal sessions after modifying PATH.
- Use
flutter --version to verify installation.
- Use
dart --version to verify Dart tooling.
- Use
flutter doctor to identify environment problems.
- Configure an IDE such as VS Code or Android Studio.
- Configure at least one target platform.
- Use
flutter devices to check available devices.
- Use
flutter create to create a project.
- Use
flutter run to run the project.
- Keep the Flutter SDK reasonably up to date and review breaking changes when upgrading.
46. JustAcademy Flutter Training
JustAcademy's Flutter training curriculum includes setting up the Flutter SDK, Android Studio/VS Code, running the first Flutter application, understanding project structure, Dart programming, OOP, widgets, navigation, API integration, Firebase, testing, debugging, and deployment. :contentReference[oaicite:21]{index=21}
Explore JustAcademy Flutter Training
Register for Flutter Course Demo
47. Conclusion
Installing the Flutter SDK is the first major step toward local Flutter application development. The basic process is to download the correct SDK, extract it to a suitable location, add its bin directory to PATH, verify the Flutter and Dart commands, run flutter doctor, configure an IDE and target platform, and finally create and run a test application.
Once this setup is complete, developers can begin learning Dart, building Flutter widgets, creating user interfaces, connecting APIs, working with databases and Firebase, testing applications, and eventually deploying Flutter applications to supported platforms.