Updated June 2026. Tested on Flutter 3.x and Dart 3. Part of the Techalyst Flutter series.

Setting an app icon by hand means producing a dozen sizes for Android, another set for iOS, and dropping each one into the right folder. It is tedious, easy to get wrong, and you have to redo it every time the icon changes. The flutter_launcher_icons package does the whole thing from a single source image and one command.

Setup

Add the package to your dev_dependencies, since it is a build-time tool you never ship inside the app:

dev_dependencies:
  flutter_launcher_icons: ^0.14.0

Then put your source icon somewhere in the project, usually assets/icon/icon.png. Use a square 1024 by 1024 PNG so every downscaled size stays crisp.

Configure it

The configuration goes in your pubspec.yaml (or a separate flutter_launcher_icons.yaml). A typical setup covers both platforms and Android's adaptive icons:

flutter_launcher_icons:
  android: true
  ios: true
  image_path: "assets/icon/icon.png"
  min_sdk_android: 21
  adaptive_icon_background: "#0d1117"
  adaptive_icon_foreground: "assets/icon/foreground.png"
  remove_alpha_ios: true

A few of these matter more than they look. Android adaptive icons are made of a background and a foreground layer, so the system can mask them into whatever shape the launcher uses, a circle, a squircle, a rounded square. The background can be a colour or an image, and the foreground is your logo with padding around it. On iOS, remove_alpha_ios: true is important, because the App Store rejects icons that have transparency, and this flattens it for you.

Generate

Run the tool, and it writes every icon size into the correct Android and iOS locations:

dart run flutter_launcher_icons

That single command replaces all the manual file juggling. Rebuild the app and your new icon is on the home screen.

A couple of tips

Re-run the command whenever the icon changes, it is not a one-time thing. The generated icon files are real files in your android and ios folders, so commit them, otherwise a fresh checkout or a CI build will not have them. And design the foreground with breathing room, because adaptive icon masks crop the edges, so a logo that fills the whole square will get clipped.

Wrapping up

flutter_launcher_icons turns app icons from a chore into a config block. Point image_path at a 1024 pixel source, set the Android adaptive background and foreground, flatten alpha for iOS, and run dart run flutter_launcher_icons to produce every size for both platforms at once. Re-run it when the art changes, commit the output, and keep the foreground padded so the adaptive mask does not clip it. That is the entire app-icon workflow, done in a minute instead of an afternoon.