Logo Quiz icon

Fonctionnalités

Documentation

Guide de configuration pour Logo QuizVisuella

AdMob

AdMob is one of the two mediation options that ship with the app. Enable either AdMob or AppLovin — enabling both at once is not supported.

Out of the box, ADMOB_IS_ENABLED=false and the SDK is not initialized. The app runs and builds normally without any AdMob account.

1. Create your AdMob account and app

Sign in at admob.google.com, create an Android app and an iOS app that match the Android package name and iOS bundle ID you set under Identifiers.

Note down each app's App ID — the string that looks like ca-app-pub-XXXXXXXXXXXXXXXX~YYYYYYYYYY.

2. Create ad units

For each platform, create two ad units:

  • Interstitial — the full-screen ad shown between games.
  • Rewarded — the opt-in ad that hands the player extra coins.

Note down each ad unit ID — ca-app-pub-XXXXXXXXXXXXXXXX/YYYYYYYYYY.

3. Fill in setup.html

Open setup.htmlConfigurations → AdMob and fill:

  • ADMOB_IS_ENABLEDtrue
  • ADMOB_ANDROID_APP_ID, ADMOB_IOS_APP_ID
  • ADMOB_ANDROID_INTERSTITIAL_ID, ADMOB_IOS_INTERSTITIAL_ID
  • ADMOB_ANDROID_REWARDED_ID, ADMOB_IOS_REWARDED_ID

Save. When the sync step runs, it patches the AndroidManifest.xml meta-data and iOS Info.plist GADApplicationIdentifier from these values.

AdMob ad units in setup.html

Tuning the interstitial frequency

The interstitial is shown every N completed games, controlled by:

code
ADS_INTERSTITIAL_EVERY_N_GAMES=3

Set it too aggressively and you'll damage retention. 3 is a reasonable default; watch your D1 and D7 retention after any change.

Test ads first

Until your account is verified by Google, the placeholder App IDs baked into the source (ca-app-pub-3940256099942544~...) are Google's test IDs — they serve safe test ads with no risk of a policy strike. If you leave ADMOB_IS_ENABLED=false or leave the fields empty, the sync step keeps those test IDs in place.

Never test with your production ad unit IDs — a few click loops from your own device is enough for Google to freeze your account.