Change flutter App version Code and Minimum SDK version



To change the version code and the minimum SDK version in a Flutter app, you’ll need to update the version and minSdkVersion fields in the android/app/build.gradle file.

Here’s how you can do it:

  1. Open the android/app/build.gradle file in your Flutter project.
  2. n the defaultConfig block, update the versionCode and versionName fields to set the app’s version code and version name, respectively. The version code is an integer value that increments with each release, while the version name is a string value that is displayed to users.
  3. In the same block, update the minSdkVersion field to set the minimum SDK version that your app supports. This is the lowest version of Android that your app is compatible with.
  4. Save the file and rebuild your app to apply the changes.

Here’s an example of what the defaultConfig block in the build.gradle file might look like after updating the version code, version name, and minimum SDK version:

defaultConfig {
    // Set the app's version code and version name
    versionCode 1
    versionName "1.0.0"

    // Set the minimum SDK version
    minSdkVersion 21
    ...
}

How to change the flutter App version Code and Minimum SDK version

Read Also: Flutter Generate or Release apk and Flutter ISO Button Style Tutorial

Leave a Comment