Tutorial: Optimize AdMob ad frequency

Step 1: Use AdMob to create new ad unit variants for testing


Introduction: Optimize AdMob ad frequency using Firebase

Step 1: Use AdMob to create new ad unit variants for testing

Step 2: Set up an A/B test in the Firebase console
Step 3: Handle Remote Config parameter values in your app's code
Step 4: Start the A/B test and review the test results in the Firebase console
Step 5: Decide whether to roll out the new ad format


To get started, you first need to create new ad units and then implement the ads in your app's code.

This tutorial uses the interstitial ad format as the example test case. When reading this tutorial, though, keep in mind that you could follow similar steps to implement and test frequency capping for other ad formats.

Create an ad unit

<span class=AdMob UI showing how to create a new interstitial ad unit">

  1. In your AdMob account, create a new Interstitial ad unit.

  2. Set the frequency cap:

    1. Expand the Advanced settings in the AdMob UI, then enable Frequency capping.

    2. Specify an ad frequency that you want to test. Choose a frequency that's higher than the frequency used in your existing ad unit.

    For example, suppose your existing interstitial ad unit shows 4 impressions per user per 10 minutes, but you want to test out if you can increase the cap to 6 impressions per user per 10 minutes.

    We recommend keeping the time duration (that is, "per 10 minutes") consistent across the ad units being compared. The other ad unit settings, though, aren't important for this particular tutorial, so select settings that are appropriate for your app.

    <span class=AdMob UI showing how to set the frequency capping for the new ad unit" class="screenshot">
  3. Repeat the steps above if you’d like to add another interstitial unit to test out an even higher frequency cap. For this tutorial, we created another ad unit with 8 impressions per user per 10 minutes.

Implement the ad unit

<span class=AdMob UI displaying new ad unit ID and instructions for integrating the SDK">

After you create each ad unit, AdMob provides you with the ad unit's unique ad unit ID. Remember where to find this ad unit ID in your AdMob account as you'll need it to implement the ad into your app.

Follow the on-screen instructions to integrate the Google Mobile Ads (AdMob) SDK and to implement the new ad unit into your app.

After creating two new interstitial ad units, you should now have three ad units listed in your AdMob account for this specific app. In the next steps of this tutorial, you'll configure Firebase to use each of these ad units in an A/B test using the same ad placement.

<span class=AdMob UI displaying all ad units for the app" class="screenshot">




Introduction Step 2: Set up an A/B test in the Firebase console