Installation
What you get from itch.io
After purchasing, download addons.zip — extract and copy the addons/ folder into the root of your Godot project.
addons/admob/ folder must be at the project root. Do not rename the folder — the plugin path is hardcoded in export_plugin.gd.Enable the Plugin
- Open your project in Godot 4.4
- Go to Project → Project Settings → Plugins
- Find AdMob in the list and toggle it ON
- Godot automatically adds
AdMobas a global autoload singleton
Screenshot: Project Settings → Plugins → AdMob enabled
AdMob. — autocomplete should show all methods.Install Android Build Templates
android/build/ folder — including AndroidManifest.xml — does not exist until you install the build templates. Without this, you cannot configure your AdMob App ID.- Go to Project → Install Android Build Template…
- Click Install — Godot downloads and extracts the template
- After installation, confirm the folder exists:
android/build/AndroidManifest.xml
Screenshot: Project → Install Android Build Template menu item
Add Your AdMob App ID
Edit AndroidManifest.xml
Open android/build/AndroidManifest.xml in any text editor. Find the <application> tag and add the following <meta-data> block inside it:
<application android:label="@string/godot_project_name_string" ...> <!-- ADD THIS BLOCK inside <application> --> <meta-data android:name="com.google.android.gms.ads.APPLICATION_ID" android:value="ca-app-pub-XXXXXXXXXXXXXXXX~XXXXXXXXXX"/> </application>
ca-app-pub-XXXXXXXXXXXXXXXX~XXXXXXXXXX with your actual AdMob App ID from your AdMob dashboard. This is NOT your ad unit ID — it's the App ID (the one with the tilde ~ character).Screenshot: AndroidManifest.xml open in editor showing the meta-data block location
Screenshot: AdMob dashboard → App → App ID location
Export Settings
1. You must use a Release Keystore. Debug keystore does not work with AdMob.
2. You must Export as Release APK. Do NOT use One-Click Deploy.
Android Export Preset — Required Settings
── Gradle Build ───────────────────────────── [✓] Use Gradle Build [✓] Use Custom Build ── Permissions ────────────────────────────── [✓] INTERNET [✓] ACCESS_NETWORK_STATE ── Keystore (REQUIRED for real ads) ───────── Release Keystore: path/to/your-release.keystore Release User: your_key_alias Release Password: your_password ── Export ──────────────────────────────────── Export Format: APK ← use Export button, NOT one-click deploy Build Mode: Release
Screenshot: Export dialog with Gradle Build enabled and permissions checked
Using the Ads
5 Ad Types Available
Banner
Top or bottom strip. Load once, show/hide as needed.
Interstitial
Full-screen. Show between levels or scene changes.
Rewarded
Video with reward. Player opts in for coins, lives etc.
Rewarded Interstitial
Full-screen rewarded. Auto-shown at natural breaks.
App Open
Shown on launch. Auto-loads on plugin init.
Test Ad Unit IDs — Always use during development
| Ad Type | Test ID |
|---|---|
| Banner | ca-app-pub-3940256099942544/6300978111 |
| Interstitial | ca-app-pub-3940256099942544/1033173712 |
| Rewarded | ca-app-pub-3940256099942544/5224354917 |
| Rewarded Interstitial | ca-app-pub-3940256099942544/5354046379 |
| App Open | ca-app-pub-3940256099942544/9257395921 |
admob.gd. Just call AdMob.initialize() and it works in development. Swap to your real AdMob IDs only when building your release APK.Call Order — Always load before show
load_*() before show_*(). Calling show before load = nothing happens, no error.extends Node func _ready(): # 1. Set your production Ad Unit IDs (swap from test IDs) AdMob.set_banner_ad_unit("ca-app-pub-XXXX/XXXX") AdMob.set_interstitial_ad_unit("ca-app-pub-XXXX/XXXX") AdMob.set_rewarded_ad_unit("ca-app-pub-XXXX/XXXX") AdMob.set_rewarded_interstitial_ad_unit("ca-app-pub-XXXX/XXXX") AdMob.set_app_open_ad_unit("ca-app-pub-XXXX/XXXX") # 2. Initialize — must come after setting ad units AdMob.initialize() # 3. Preload all ads AdMob.load_banner("bottom") # "top" or "bottom" AdMob.load_interstitial() AdMob.load_rewarded() AdMob.load_rewarded_interstitial() AdMob.load_app_open() # auto-called by plugin on init # 4. Connect signals AdMob.connect("interstitial_closed", _on_interstitial_closed) AdMob.connect("rewarded_interstitial_earned", _on_reward_earned) # ── Banner ────────────────────────────────────────────────── func show_banner(): AdMob.show_banner() func hide_banner(): AdMob.hide_banner() # ── Interstitial (between levels) ─────────────────────────── func on_level_complete(): if AdMob.is_interstitial_loaded(): AdMob.show_interstitial() # wait for interstitial_closed signal before changing scene else: change_scene() func _on_interstitial_closed(): AdMob.load_interstitial() # reload immediately for next time change_scene() # ── Rewarded (revive / coins) ──────────────────────────────── func offer_revive(): if AdMob.is_rewarded_loaded(): AdMob.show_rewarded() else: print("Rewarded not ready yet") # ── Rewarded Interstitial ──────────────────────────────────── func _on_reward_earned(): give_player_reward() AdMob.load_rewarded_interstitial() # reload for next
Switching to Production IDs
When building your release APK, swap the test IDs with your real ones from the AdMob dashboard. Best practice is to use a config approach:
extends Node # Returns test IDs in debug, real IDs in release static func banner_id() -> String: if OS.is_debug_build(): return "ca-app-pub-3940256099942544/6300978111" return "ca-app-pub-YOURREAL/BANNERID" static func interstitial_id() -> String: if OS.is_debug_build(): return "ca-app-pub-3940256099942544/1033173712" return "ca-app-pub-YOURREAL/INTERSTITIALID" static func rewarded_id() -> String: if OS.is_debug_build(): return "ca-app-pub-3940256099942544/5224354917" return "ca-app-pub-YOURREAL/REWARDEDID"
Mediation Setup
What is Mediation?
Mediation lets AdMob automatically pick the highest-paying ad network for each impression. Instead of only showing Google ads, it runs a real-time auction across multiple networks — increasing your fill rate and revenue.
Supported Networks via AdMob Mediation
How to Set Up Mediation (AdMob Dashboard)
- Open admob.google.com and go to your app
- Click Mediation → Create mediation group
- Select your ad format (Interstitial / Rewarded / Banner)
- Add ad sources — pick Unity Ads, Meta, AppLovin etc.
- Enter each network's ad unit IDs (from their dashboards)
- Save — AdMob handles the waterfall/bidding automatically
Screenshot: AdMob Mediation dashboard — Create mediation group
Debugging & Common Issues
Step-by-Step Diagnostic — Ads Not Showing
| STEP | WHAT TO CHECK |
|---|---|
|
ST 1
Correct method
|
Check you are using the right method from the singleton. AdMob is a global autoload — call AdMob.show_banner() not admob.show_banner(). Also confirm load_*() was called before show_*().
|
|
ST 2
AdMob stats
|
AdMob takes time to serve real ads. Open your AdMob dashboard → Reports. Check if ad requests are being received. If requests show but fill rate is 0%, your account may be pending review or your app isn't verified yet. |
|
ST 3
Play Store listing
|
Your app must be listed on the Play Store to serve real ads. AdMob verifies your app through the store listing. Apps distributed only via direct APK may not pass verification. Publish to at least internal testing on Play Store to enable full ad serving. |
|
ST 4
Firebase Analytics
|
Set up Firebase Analytics linked to your AdMob app. Link your AdMob app to Firebase in the AdMob dashboard under App Settings. Firebase analytics helps AdMob verify your app and improves ad targeting, which increases fill rate and eCPM. |
Common Error Reference
| SYMPTOM | CAUSE & FIX |
|---|---|
| AdMob singleton not found | Plugin not enabled — Go to Project Settings → Plugins and enable AdMob. Also confirm the addons/admob/ folder is in your project root. |
| App crashes on launch | Missing AndroidManifest meta-data — AdMob requires the App ID <meta-data> block in AndroidManifest.xml. Without it the app crashes on Android 9+. |
| Ads show in debug but not release | Test IDs used in release build — Replace all test IDs with your real AdMob ad unit IDs before exporting release APK. |
| Ads never load (no error) | Debug keystore used — Export using your release keystore. Debug-signed APKs cannot load real AdMob ads. |
| Gradle build fails | Gradle or permissions not enabled — In Export settings, enable "Use Gradle Build" and check INTERNET + ACCESS_NETWORK_STATE permissions. |
| Banner not visible | show_banner() called before load_banner() — Always call load_banner("bottom") first, then show_banner() after it's loaded. |
| Interstitial shows, then scene doesn't change | Not waiting for signal — Connect to AdMob.interstitial_closed signal before changing scenes. Change scene inside the signal handler. |
Logcat — Reading Android Logs
# Connect your device via USB, then: adb logcat | grep -i admob adb logcat | grep -i "Ads" adb logcat | grep -i "Godot" # Look for these messages: "AdMob plugin loaded with test ad units" ← plugin found ✓ "AdMob plugin not found" ← plugin missing ✗