0
0
FlutterHow-ToBeginner · 4 min read

How to Install Flutter on Mac: Step-by-Step Guide

To install Flutter on a Mac, first download the latest Flutter SDK from the official website, then extract it and add flutter/bin to your system PATH. Finally, run flutter doctor in the terminal to verify the installation and install any missing dependencies.
📐

Syntax

Here is the basic syntax to install Flutter on Mac using the terminal commands:

  • Download Flutter SDK: Get the latest stable version from the official Flutter website.
  • Extract SDK: Unzip the downloaded file to a desired location.
  • Update PATH: Add the flutter/bin directory to your shell's PATH environment variable.
  • Verify installation: Run flutter doctor to check setup and dependencies.
bash
mkdir -p ~/development
cd ~/development
curl -O https://storage.googleapis.com/flutter_infra_release/releases/stable/macos/flutter_macos_3.7.12-stable.zip
unzip flutter_macos_3.7.12-stable.zip
export PATH="$PATH:$HOME/development/flutter/bin"
flutter doctor
💻

Example

This example shows how to download Flutter, extract it, add it to your PATH, and verify the installation on Mac.

bash
mkdir -p ~/development
cd ~/development
curl -O https://storage.googleapis.com/flutter_infra_release/releases/stable/macos/flutter_macos_3.7.12-stable.zip
unzip flutter_macos_3.7.12-stable.zip
export PATH="$PATH:$HOME/development/flutter/bin"
flutter doctor
Output
Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel stable, 3.7.12, on macOS 13.4 22F66 darwin-arm, locale en-US) [✓] Xcode - develop for iOS and macOS [✓] Chrome - develop for the web [✓] Android Studio (version 2022.2) [✓] Connected device (2 available) • No issues found!
⚠️

Common Pitfalls

Common mistakes when installing Flutter on Mac include:

  • Not adding flutter/bin to the PATH, so the flutter command is not found.
  • Skipping flutter doctor, missing important setup steps like Xcode or Android Studio installation.
  • Not installing Xcode command line tools, which are required for iOS development.
  • Using an outdated Flutter SDK version.

Always follow the latest official instructions and verify with flutter doctor.

bash
export PATH="$PATH:$HOME/development/flutter/bin"
flutter doctor
📊

Quick Reference

Summary tips for installing Flutter on Mac:

  • Download the latest stable Flutter SDK from flutter.dev.
  • Extract to a permanent location like ~/development/flutter.
  • Add flutter/bin to your PATH in .zshrc or .bash_profile.
  • Run flutter doctor to check and fix setup issues.
  • Install Xcode and Android Studio for iOS and Android development.

Key Takeaways

Download the latest Flutter SDK from the official website for Mac.
Add the Flutter SDK's bin directory to your PATH environment variable.
Run flutter doctor to verify installation and fix missing dependencies.
Install Xcode and Android Studio for full mobile development support.
Keep Flutter updated to avoid compatibility issues.