androidfirebaseadmobmobile-ad-mediation

How to use AdMob Ad Mediation in Android App?


Hi I have used Firebase SDK to integrate AdMob in my Android App. Ads are working fine in my App. Now I want to enable Ad Mediation. I know how to add third party Ad networks in AdMob portal.

Confusion is that do I need to add/change specific code in Android App also? Do I need to change the banner ad code implemented in App? Or Firebase SDK will handle automatically and will show third party ads on same banner? Please help.


Solution

  • You should not need to change your banner code. You do need to compile the SDKs for the networks you want to mediate, plus their adapters into your app, though. The Mobile Ads SDK (firebase-ads, since you're using Firebase on Android) will use those SDKs through the adapters, and put the ads into the AdView you're already using. You don't need to write any additional Java code, though.

    We have a mediation guide to help, as well as a video tutorial, if you're interested. There's also a directory that can point you to the SDKs and adapters.