Build and Release Android App:

Build and Release Android App

  • Add the package name build identifier [Important]

The package name or application id is a unique identifier for the app. So you must change this to your own. 

Make sure that your current working directory is the project root.

Make sure to be able to get back to the previous state in case something went wrong, by committing your work before running the package for example.

flutter pub get

flutter pub run flutter_rename_app_plus

  • Update app version:

Every app has a version. Whenever you build a new version you should update the version. This is how you will update the version of the app in a flutter.

Open pubspec.yaml file. 

  • You will see there is a variable named version. Currently, the version is 1.0.0+1. 1.0.0 is the version and after the ‘+’ sign, 1 is the build number. You can change the build number every time you build a new app.
  • Firebase Setup:

First of all, create a project in the Firebase console named your app.

  • Go to https://console.firebase.google.com/
  • Create a project.

If you already have one, just open the console with that project.

  • When your project is created, you will see your dashboard like this.
  • Tap the settings button in the left corner. A pop-up menu will appear. Click on ‘Project settings’ from the pop-up menu. The settings page will open. 
  • Scrolling down you will find ‘SDK setup and configuration’. Click on ‘Add fingerprint’ to add the SHA key

So for the first one, let’s find out your debug fingerprint. 

Generate SHA-1 for Flutter/React-Native/Android-Native app from this link, You will find a lot of ways to find the debug SHA-1 fingerprint. With this debug fingerprint, you can test your app in the debug mode. 

  • Time to run the app in the simulator:

All the configuration has been made. Now it’s time to run your app in the emulator.

  • Signing, Building APK or AppBundle, and releasing the android app:

For this step, you have to follow the default steps from the flutter team.

Browse Build and release an Android app. Follow all the steps here except the first one as you already did that. 

After completing all the steps above you are finished building the app for android!

Was this page helpful?

Leave Comment