IonIcons not being displayed after generating APK or AAB

Hi! I have recently updated an android app to Ionic/Core 7.x and Capacitor 5 +++. When testing the app locally everything works fine, but when testing with “adb install -r ‘[APK]’” after generating an APK Ion-icons are not being displayed.

Relevant package.json scripts are listed below.

  • “dev:android”: “env-cmd -e development,all run-p dev:start cap-run:android”,
  • “dev:start”: “run-p dev:vite”
  • “dev:vite”: “env-cmd -e development,all vite --host --port 8100”,
  • “cap-run:android”: “cap sync android && cap open android”,
  • “build:android:prod”: “env-cmd -e production,all run-s build:app:prod cap-run:android”,
  • “build:app:prod”: “env-cmd -e production,all vite build”,

The following process results in ion-icons being displayed.

  • npm run dev:android’
  • Android Studio → ‘Run’.

The following process results in ion-icons NOT being displayed.

  • npm run build:android:prod
  • Android Studio → Build → Generate Signed APK → install apk through “adb install -r [APK]”

Any ideas as to why Ion-icons are not being displayed through the APK?

PS: I am fairly new to app development, so please let me know if more info is needed.

1 Like

try these commands:

  • ionic build --prod
  • npx cap copy
  • npx cap open android

see what happens


  • Android Studio → Build → Generate Signed APK → install apk through “adb install -r [APK]”

if you have android studio why not connecting your phone through usb cable or wifi connection and install the apk directly from there?

Hi! Thanks for the reply!

I like to use the adb install -r [..]to verify that everything is included in the APK/AAB before publishing. I wasn’t aware that Android Studio could install the APK for me.

Managed to navigate around my issue by using icons from svelte-ionicons instead.

In the end, I don’t know what the issue really was, but I think it had something to do with certain assets not being copied correctly before running vite build (application config issue). That resulted in the ion-icons not being present in the build when generating a signed APK.