iOS AdMob ads not showing up unless on Test Device

Mike Simz picture Mike Simz · Nov 18, 2014 · Viewed 16.5k times · Source

I have followed the tutorial provided by Google here: https://developers.google.com/mobile-ads-sdk/docs/admob/ios/quick-start in order to setup admob banner ads.

My code is exactly how it is shown in the guide from the link above, so when I run the app on my test device or simulator a 'Smart Banner' 'Test Ad' appears..however, the second I remove the line of code below no banner appears at all..

 request.testDevices = @[ @"70b9ee4e66c8e6fa26cb84def25706d9" ];

Also, I've loaded the app on another device and still there is no ad banner appearing, which makes me wonder when I submit the app to the App Store it only makes sense that all my users won't be seeing ads on their devices. Why is this happening? I've been scratching my head on this one! I don't want to submit it for review until I am certain everything is working correctly and I know that ads will appear not only on test devices but when the app goes LIVE as well. Thanks in advance! :)

Answer

Dheeraj Gupta picture Dheeraj Gupta · Jun 14, 2018
-(void)adViewDidReceiveAd:(GADBannerView *)bannerView;
-(void)adView:(GADBannerView *)bannerView didFailToReceiveAdWithError:(GADRequestError *)error;

There can be number of reasons for not showing the Live ads.

  1. Check your google admob account for the payment info. If not filled, fill it.
  2. Check if your device is registered as test device, else you may get suspension from the google for 30 days or so.
  3. You can check the delegate methods and print the logs:

In my case, I was getting error as { 'error': 'Request Error: No ad to show.', 'adType':'banner' }

But it showed at the client side, after I delivered to the client. So, I think that this issue was due to the reason that google had no advertisements in my region.