AfriGuardAfriGuard

Android Icon Setup

Replace the default Android icon with your AfriGuard logo

Your AfriGuard App Icon
AfriGuard Icon

This icon has been generated for AfriGuard. Download it and resize for each Android density.

Required Icon Sizes

mipmap-mdpi

android/app/src/main/res/mipmap-mdpi/ic_launcher.png

48×48px

mipmap-hdpi

android/app/src/main/res/mipmap-hdpi/ic_launcher.png

72×72px

mipmap-xhdpi

android/app/src/main/res/mipmap-xhdpi/ic_launcher.png

96×96px

mipmap-xxhdpi

android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png

144×144px

mipmap-xxxhdpi

android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png

192×192px

Step-by-Step Instructions

1

Download the AfriGuard logo

Download the generated icon above. You'll need to resize it for each density.

2

Resize the icon for each density

Use a tool like Android Asset Studio, Figma, or ImageMagick to resize the icon to the required dimensions:

# Using ImageMagick (run in your project root):
convert icon.png -resize 48x48   android/app/src/main/res/mipmap-mdpi/ic_launcher.png
convert icon.png -resize 72x72   android/app/src/main/res/mipmap-hdpi/ic_launcher.png
convert icon.png -resize 96x96   android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
convert icon.png -resize 144x144 android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
convert icon.png -resize 192x192 android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png

# Also create round variants:
convert icon.png -resize 48x48   android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
convert icon.png -resize 72x72   android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
convert icon.png -resize 96x96   android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
convert icon.png -resize 144x144 android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
convert icon.png -resize 192x192 android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
3

Update AndroidManifest.xml

Ensure your AndroidManifest.xml has the correct icon references (this is the default Capacitor setup):

<!-- android/app/src/main/AndroidManifest.xml -->
<application
    android:allowBackup="true"
    android:icon="@mipmap/ic_launcher"
    android:roundIcon="@mipmap/ic_launcher_round"
    android:label="@string/app_name"
    android:theme="@style/AppTheme"
    ...>
4

Update capacitor.config.ts (optional shortcut)

Capacitor can auto-generate icons if you place a 1024x1024 source image in your project root and run the icon generator plugin:

# Install @capacitor/assets
npm install @capacitor/assets --save-dev

# Add a 1024x1024 icon at:
# resources/icon.png   (your AfriGuard logo, 1024x1024)

# Then run:
npx @capacitor/assets generate --android
5

Rebuild the Android project

After placing the icons, rebuild the APK:

# Sync Capacitor
npx cap sync android

# Build the APK (or open in Android Studio)
npx cap open android
# Then in Android Studio: Build → Generate Signed Bundle/APK

Easiest Method

The fastest approach is using @capacitor/assets (Step 4). Just download the icon above, save it as resources/icon.png at 1024×1024px in your project root, then run npx @capacitor/assets generate --android. It handles all densities automatically!

After rebuilding, your AfriGuard icon will appear on all Android devices.