XF 2.1 Some questions on Ads 'Above Container content'

Browsing around this forum, it seems that 'Container content: Above' is the most recommended ad location (along with others).
When using a responsive ad unit, this ad unit seems great on desktops however on mobile, it usually loads a 300x250 or similar sized banner.
This banner is just below Header and the content is pushed below fold i.e the banner is all visitor sees before scrolling.

What are your views (point of view not ad views ;)) on this ad location? Is it worth it on mobile or are you folks using something else?

P.S. I have that ad unit hidden on mobile ATM and using an ad below first post instead (mobile only).
 
since you are using responsive. and i assume google. google is making the choice to load a full sized ad there. earlier this used to be a problem with adsense policies as the content was below the fold. but now they themselves are pushing these ads. so on that angle you are safe.

i was personally annoyed with this as well so i am now using css to resize the ad to a smaller size. you also have the option to just use horizontal setting (data-ad-format="horizontal") in the code and smaller bar would appear in the place of the square.
 
Agreed but data-ad-format="horizontal" only works on desktop and it would still fire up a 300x250 banner on mobile. This can be overridden with CSS but that causes another issue. This would need a fixed height and a 320x100 would be great but often google would throw in a 320x50 ad instead which would leave a 50px margin. Do you have this problem with your CSS resize?
 
Last edited:
i have tried horizontal code on my website and it changed the box layout to rectangle layout on mobile 🤔 . but yeah... it can show a smaller ad size on some page loads resulting in empty space when css size is defined.
 
you seem to be right. i am not sure how it worked for me before. i definitely remember using that code. i guess i would stick to css to keep control on the top ad placement. with horizontal bar sizing defined, there should be very low probability of empty margin around the ad!
 
That's actually the first thing I tried.
Its been here for a while: https://support.google.com/adsense/answer/9183363?hl=en
(In 'Specify an expandable width and a fixed height' section).

But nothing works. In Mobile, the unit just loads a 300x250 banner.

As a last resort, I made 2 units, one responsive for desktop/tablets and the other with fixed height on mobile.
This works as intended with the following CSS:

HTML:
<style>
@media (max-width:650px){.mobile-display-none{display:none!important}}
@media (min-width:650px){.desktop-display-none{display:none!important}}
</style>
<div align="center"> <!--without this the mobile banner will just stick to left regardless of any center css in ins tag-->
<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<ins class="adsbygoogle mobile-display-none"
     style="display:block"
     data-ad-client="ca-pub-xxxxxxxxxxxxxxxx"
     data-ad-slot="xxxxxxxxxx"
     data-ad-format="horizontal"
     data-full-width-responsive="true"></ins>
<ins class="adsbygoogle desktop-display-none"
     style="display:inline-block;width:320px;height:100px"
     data-ad-client="ca-pub-xxxxxxxxxxxxxxxx"
     data-ad-slot="xxxxxxxxxx"></ins>
<script>
     (adsbygoogle = window.adsbygoogle || []).push({});
</script>
</div>
 
Back
Top Bottom