Search code examples
androidviewadmoborientationinterstitial

Android interstitial ads orientation


is it possible to force interstitial Ads orientation to be portrait only ?

this is my code:

final PublisherInterstitialAd interstitialAd = new PublisherInterstitialAd(context);
interstitialAd
.setAdUnitId(adUnitId);

PublisherAdRequest adRequest = new PublisherAdRequest.Builder().build();
interstitialAd.loadAd(adRequest);

Solution

  • No, and you would not want to.

    The ads should be displayed in whatever orientation the user has the device. Forcing it to do otherwise provides a poor experience for the user and excessive and convoluted coding for you.