No matter which Flutter release channel you follow,
you can use the
flutter command to upgrade your Flutter SDK
and the packages that your app depends on.
flutter command to work correctly,
pubspec.yaml file must require the Flutter SDK.
For example, the following snippet specifies that the
flutter_test packages require the Flutter SDK:
name: hello_world dependencies: flutter: sdk: flutter dev_dependencies: flutter_test: sdk: flutter
Upgrading the Flutter SDK and packages
To update both the Flutter SDK and the packages that your app depends on,
flutter upgrade command from the root of your app
(the same directory that contains the
$ flutter upgrade
This command first gets the most recent version of the Flutter SDK that’s available on your Flutter channel. Then this command updates each package that your app depends on to the most recent compatible version.
If you want an even more recent version of the Flutter SDK,
switch to a less stable Flutter channel
and then run
Switching Flutter channels
Flutter has four release channels: stable, beta, dev, and master. We recommend using the stable channel unless you need a more recent release.
To view your current channel, use the following command:
$ flutter channel
To change to another channel, use
flutter channel <channel-name>.
Once you’ve changed your channel, use
to download the Flutter SDK and dependent packages.
$ flutter channel dev $ flutter upgrade
Upgrading packages only
If you’ve modified your
pubspec.yaml file or you want to update
only the packages that your app depends upon (instead of both the packages and
Flutter itself), then use one of the
flutter packages commands.
To get all the dependencies listed in the
without unnecessary updates, use the
$ flutter packages get
To update to the latest compatible versions of
all the dependencies listed in the
$ flutter packages upgrade
We publish breaking change announcements to our mailing list. We strongly recommend that you subscribe to get announcements from us. Plus, we’d love to hear from you!