Lucas Dahl
Lucas Dahl

Reputation: 742

AdMob ads stopped showing

I looked at various answers, but nothing works for me. This also may be a dumb question, but I haven't worked with AdMob in 2 years. It did use to show the test ads on the simulator, until I ran it on a physical device. I know that it won't show the real ads on the physical device, but now test ads do not show on the simulator. However I have the view set to a grey color and the ad view is white on the simulator. This makes me believe they are still working. I do get the below printed in the console. Doing that won't show test ads though.

To get test ads on this device, set: GADMobileAds.sharedInstance.requestConfiguration.testDeviceIdentifiers = @[ kGADSimulatorID ];

code:

let banner: GADBannerView = {
        let banner = GADBannerView()
        banner.load(GADRequest())
        banner.backgroundColor = .secondarySystemBackground
        banner.adUnitID = Constants.appBanner
        return banner
    }()

called in viewDidLoad:

banner.rootViewController = self
view.addSubview(banner)

My question is if I am doing anything wrong, or if I am being paranoid.

Upvotes: 1

Views: 138

Answers (1)

Bill Johnson
Bill Johnson

Reputation: 26

In my experience sometimes the test ads won't show or show properly, but in the console, the messages indicate they are working. If you used the code you posted just give admob time on once you've launched your to verify traffic. If after a couple of weeks they still don't show contact admob support.

Upvotes: 1

Related Questions