MoPub Android Viewability

With the growth of in-app advertising, viewability measurement has become a requirement for marketers who want metrics for and transparency into the viewability of their campaigns. Mobile app publishers who don’t offer a verified way to measure viewability may miss out on ad budgets for which this measurement is a prerequisite — especially from brands.

MoPub SDK v.5.14 and Higher: Open Measurement SDK

MoPub SDK v.5.14 and higher have integrated IAB tech lab certified technology, the Open Measurement (OM) SDK. The OM SDK offers common code and libraries for facilitating access to measurement across third-party partners. This means you only have to integrate one SDK instead of individual SDKs for each partner.

MoPub is also IAB Tech Lab Standards compliant; refer to IAB documentation for details. In addition to the IAB certification, industry verification providers such as Integral Ad Science, DoubleVerify, and Moat have independently validated the OMSDK-MoPub integration.

As a publisher, you only need to upgrade to MoPub SDK v.5.14 or higher (refer to the Android Integration Guide) to integrate the OM SDK. For more information on Open Measurement, refer to the IAB OM documentation.

Supported Ad Formats

MoPub supports viewability measurement on all ad formats on MoPub SDK v.5.14+, except for Direct Serve native and direct image upload formats.

For more information on best practices and FAQ, refer to our viewability best practices.

Open Measurement License

We have partnered with the IAB to provide Viewability measurement via the Open Measurement SDK as of MoPub SDK v.5.14.0. To view the full license, visit

MoPub SDK v.5.13 and 5.13.1

MoPub SDK versions 5.13.0 and 5.13.1 do not include a measurement SDK. Starting with MoPub SDK v.5.13.0, the Moat and IAS viewability SDKs have been removed. Viewability tracking logic is no longer operational via these proprietary SDKs.

MoPub SDK v.5.12 and Lower

This section contains legacy information. Prior to MoPub SDK v.5.13, MoPub partnered with both IAS and Moat to implement their respective measurement SDKs into our MoPub SDK through either GitHub or Maven Central.

IAS and Moat

To support viewability and other measurement reporting, MoPub SDK versions 4.16 and higher integrate technology from our partners, Moat, Inc. (“Moat”) and Integral Ad Science, Inc. (“IAS”). As a publisher, you only need to upgrade to version 4.16 or higher of the MoPub SDK (refer to the Android integration guide). You can then remove or disable this technology by following the opt-out instructions below.

If you do not remove or disable IAS’s and/or Moat’s technology in accordance with these instructions, then you agree that IAS’s privacy policy and license and Moat’s privacy policy, terms, and license, respectively, apply to your integration of these partners’ technologies into your application.

Supported Ad Formats

All display and VAST video ads are supported. MoPub will support native ads at a later date.

Integrate Viewability (Opt In)

To take advantage of viewability measurement, simply upgrade to the latest version of the MoPub SDK. Viewability is supported through the MoPub Android SDK on GitHub and Maven Central. No additional work is required.

Validate Your Integration

Validate that you have integrated properly by reviewing your device log output. Follow the instructions below. Avid is the IAS library.

  1. Validate that the Moat and IAS SDKs (also referred to as “Avid”) are present. This occurs when the initial ad is loaded in an app session, and only occurs once per app session.

    • D/MoPub: Avid is available via reflection.
    • D/MoPub: Moat is available via reflection.
  2. Banner and interstitial load: validate that the viewability session was initialized and started when an ad is loaded (on ‘load’ event).

    • D/MoPub: viewability event: initialize.
    • D/MoPub: viewability event: start display session.
  3. Interstitial Show (skip for banners): Validate that the viewability session was recorded when an interstitial is shown to the user (on ‘show’ event).

    • D/MoPub: viewability event: record deferred session.
  4. Validate that the viewability session ended. This will be present when the ad is deallocated:

    • D/MoPub: viewability event: end display session.

Opt Out of Viewability Measurement

On MoPub SDK versions 4.16 and higher, where viewability is enabled by default, follow these instructions if you want to disable it in GitHub or Maven Central.

GitHub Integration Opt-Out

Navigate to the file in your home directory (for example, ~/.gradle/ and include one or both of these lines to opt out of viewability measurement for the IAS library (also known as “AVID”) and/or Moat.

  • To exclude IAS:

  • To exclude Moat:


Maven Central Integration Opt-Out

Normally, to add the MoPub SDK to your app via Maven Central, your build.gradle would contain:

    dependencies {
        compile('com.mopub:mopub-sdk:5.X.X@aar') {
            transitive = true

Update to the following to exclude one or both viewability vendors:

     dependencies {
        compile('com.mopub:mopub-sdk:5.X.X@aar') {
            transitive = true
            exclude module: 'libAvid-mopub' // To exclude AVID
            exclude module: 'moat-mobile-app-kit' // To exclude Moat

Note: Moat does not use AndroidX libraries yet. Turn on Jetifier by adding android.enableJetifier=true and android.useAndroidX=true in of your project to avoid app crashes.

Validate Your Opt-Out

You can validate that you have correctly opted out if there are no IAS or Moat logs in the device log output.


You can also receive reporting on your direct campaigns through IAS or Moat if you have direct relationships with either partner. To collect viewability measurement, add the IAS or Moat tags that you received from your partner to the HTML creative in the MoPub UI.

Reporting can be broken out by app, ad unit, line item, creative ID, and other dimensions, by inserting MoPub macros into the IAS or Moat tags. For more information on supported fields, review our list of macros.

To view human-readable names in the Moat or IAS UI, you must provide a mapping of IDs to names to each partner. You can access the IDs and their associated names through the Publisher Reporting API Campaign Report.

Last updated August 28, 2021

TWITTER, MOPUB, and the Bird logo are trademarks of Twitter, Inc. or its affiliates. All third party logos and trademarks included are the property of their respective owners.

© 2021 MoPub (a division of Twitter, Inc.)