skip to Main Content

Its starting app size is 17 MB. When developing the app, It’s increasing the size from 17MB.
How to reduce the size of flutter given app (First project)

I used this method to get android app

flutter build apk --build-name=0.1 --build-number=2

2

Answers


  1. According to the Official documentation of Flutter, they have various steps to analyze which part of your code is exactly taking much more space than needed.

    They have a proper guide on that, to take you through analyzing the source code, testing the app size, and giving you the information of which file or dependency is taking more size and how much it is taking.

    If you don’t want to go through it, here are some common things by which it can reduce your app size.

    1. Remove unused resources
    2. Minimize resources imported from libraries
    3. Compress PNG and JPEG files

    Here’s the official documentation if you want to read it.

    Documentation Link

    Login or Signup to reply.
  2. you can try the following

    1. Compress PNG and JPEG files
    2. reduce the use of container and replace them with SizedBox and Cards
    3. Minimize resource imported from libraries
    4. Remove unused resources
    5. the fewer the screens the better

    also you can split the apks while building it using this command

    **flutter build apk –target-platform android-arm,android-arm64 –split-per-abi
    **

    and always

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search