Ionic · Capacitor
Ionic and Capacitor App Icon and Splash Screen (@capacitor/assets)
Short answer
Install @capacitor/assets, put a 1024×1024 icon and a 2732×2732 splash in an assets/ folder, and run npx @capacitor/assets generate. It writes every iOS, Android and PWA size into your native projects.
Checked against Capacitor: Splash screens and icons and @capacitor/assets in October 2026.
Source files
| File in `assets/` | Minimum size | Use |
|---|---|---|
icon-only.png | 1024×1024 | The icon |
icon-foreground.png | 1024×1024 | Android adaptive foreground |
icon-background.png | 1024×1024 | Android adaptive background |
splash.png | 2732×2732 | Splash screen |
splash-dark.png | 2732×2732 | Dark mode splash |
PNG or JPG. The tool also accepts a resources/ folder.
Easy mode: put only assets/logo.png (and optionally logo-dark.png) there. The tool builds icons and splash screens from it with background colors you pass in.
Generate
npm install --save-dev @capacitor/assets
npx @capacitor/assets generatenpx @capacitor/assets generate \
--iconBackgroundColor '#eeeeee' \
--iconBackgroundColorDark '#222222' \
--splashBackgroundColor '#eeeeee' \
--splashBackgroundColorDark '#111111'| Flag | Default | What it does |
|---|---|---|
--ios / --android / --pwa | all | Only these platforms |
--iconBackgroundColor | #ffffff | Icon background in easy mode |
--splashBackgroundColor | #ffffff | Splash background in easy mode |
--logoSplashScale | 0.2 | Logo size on the splash |
--iosProject / --androidProject | ios/App / android | Custom native folders |
Capacitor icon problems and fixes
| You see | Why | Fix |
|---|---|---|
| Old icon on the device | The native project wasn't rebuilt | Rebuild and reinstall from Xcode or Android Studio |
| Nothing generated | No assets/ or resources/ folder in the project root | Create it at the root |
| Logo cut off on Android | Foreground has no padding | Keep the logo in the middle 66/108 of icon-foreground.png |
| Splash only shows a small icon on Android 12+ | Android 12 uses an icon on a color | Expected; tune the icon and background |
| Cordova project not supported | Cordova support was removed | Use Capacitor |
FAQ
What size is the Capacitor app icon?
At least 1024×1024. The splash source is at least 2732×2732.
Is it `npx @capacitor/assets` or `npx capacitor-assets`?
The package README uses npx @capacitor/assets generate.
Does it work for Ionic?
Yes. Ionic apps use Capacitor for native builds.
Can I generate only Android?
Yes: npx @capacitor/assets generate --android.