This blog post explains how to set up and configure Flutter with Android Studio. It is assumed that Dart is already installed on the system. The shell commands were tested on Ubuntu 20.04, but they should be the same for macOS and probably similar for Windows.
For the setup of Flutter, the Flutter Version Management tool (FVM) can be used. One of the advantages of that community tool over the approach explained in the official setup instructions is that it makes it convenient to switch back and forth between different Flutter versions, since no rebuilds of the Flutter SDK are required after switching the release channel.
FVM can be installed using the Dart package manager:
dart pub global activate fvm
After the installation of the
fvm package, you should include its
bin directory into your shell profile (e.g.
To use a specific Flutter version (i.e.
master), run the
fvm global command with the required Flutter channel as a positional parameter:
fvm global beta flutter --version
When you open a new Flutter project for the first time after installing Android Studio and the Flutter plugin, it will prompt you to enable Dart support. After clicking on the "Enable Dart support" link, Android Studio tries to auto-detect your Dart and Flutter version.
You may also click on "Open Dart settings" and configure the path to the Dart and Flutter SDK manually.
Assuming the usage of FVM, the path with needs to be entered for the Dart SDK is e.g.
The path required for the Flutter SDK is e.g.