This guide covers setting up Flutter on an Apple M1 Mac, including fixing common errors with Android Studio and SDK licensing.
Steps
Step 1: Download Flutter
Get the latest stable release for macOS from the official Flutter install page.
As of writing, this was flutter_macos_2.2.0-stable.zip.
Step 2: Run Flutter Doctor
1 | flutter doctor |
This will show you what’s missing. Common issues on a fresh install:
- Android toolchain not found
- Xcode installation incomplete
- CocoaPods not installed
Step 3: Install Android Studio
Download from developer.android.com/studio and install it.
Step 4: Install Android Command Line Tools (critical step)
Android Studio does not install the Command Line Tools by default. Without them, flutter doctor --android-licenses throws a NoClassDefFoundError.
To install them:
- Open Android Studio
- Go to Preferences → Appearance & Behavior → System Settings → Android SDK
- Click the SDK Tools tab
- Check Android SDK Command-line Tools (latest)
- Click Apply and let it install

Step 5: Accept Android licenses
1 | flutter doctor --android-licenses |
Accept all prompts. If Step 4 was done correctly, this runs without errors.
Step 6: Install Xcode
Download Xcode from the Mac App Store or Apple Developer. Then run:
1 | sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer |
Step 7: Install CocoaPods
1 | sudo gem install cocoapods |
Step 8: Verify everything is working
1 | flutter doctor |
All items should show a green checkmark. You’re ready to build.
Getting Started with your first app
Try the official Flutter codelab:
Build your first Flutter app