• Resolved fabiocrispim

    (@fabiocrispim)


    Hello!!

    So I’ve had autoptimize installed on my WordPress website for a while now and a couple of months back, I noticed that my Google Adsense ads were not showing. After some experimenting, I found that enabling the “Aggregate all linked JS-files to have them loaded non-render blocking?” option stops Google Adsense from appearing on my website.

    Do you know why this might be happening? I’d like to keep that option enabled to help site speed and Google PageSpeed, but it affects my earnings and reduces them to zero when it’s enabled.

    I have the option unchecked right now.

    Any help would be appreciated!

    Thanks.

    The page I need help with: [log in to see the link]

Viewing 13 replies - 1 through 13 (of 13 total)
  • Plugin Author Optimizing Matters

    (@optimizingmatters)

    Did you have “also aggregate inline JS” active Fabio?

    Thread Starter fabiocrispim

    (@fabiocrispim)

    Hello!!

    No, I didn’t. Should I enable it too?

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    no, I would advice against that actually, but the only JS that interacts with Google Ads is inline which is why I thought that might have been the reason.

    do the ads display when you enable “don’t aggrgate but defer” ?

    Thread Starter fabiocrispim

    (@fabiocrispim)

    I’ll enable that and monitor the ads over the next few hours. Will let you know what happens.

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    ah, so they don’t disappear immediately, but after some time? does your adsense dashboard mention anything relevant when this happens?

    Thread Starter fabiocrispim

    (@fabiocrispim)

    Yeah, they don’t immediately disappear. Always takes a bit of time. Adsense doesn’t mention anything, just my earnings and impressions plummet.

    For example, a quick look at my dashboard says I had 3.82K ad impressions when the “Aggregate all linked JS-files to have them loaded non-render blocking?” was off one day last week and 20 impressions yesterday when it was switched on. That’s a major difference with around the same traffic numbers.

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    So how are ad impressions going with the new JS optimization configuration Fabio?

    Thread Starter fabiocrispim

    (@fabiocrispim)

    I’ve been checking them and they’re good! No issues now.

    But since the “Aggregate all linked JS-files to have them loaded non-render blocking?” option is turned off, my pagespeed has dipped a little. On mobile from 80 when turned on to around 50 now with it off. But I guess there’s no way to address this?

    I’ve also been speaking with Mediavine and moving onto their ad network, but Google was having trouble finding their script on my website after I added it. I believe this may have been caused by having the “Aggregate all linked JS-files to have them loaded non-render blocking?” option checked on at the time.

    They’ve contacted Google about it and they’re trying again now that the option is set to off. I’ll let you know if anything changes there when I hear from them, but do you think that option is blocking code or something? Or could this be an issue with my theme?

    Would love to have it enabled to speed up my website without causing issues with Adsense/Mediavine.

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    I believe this may have been caused by having the “Aggregate all linked JS-files to have them loaded non-render blocking?” option checked on at the time.

    so you don’t have “don’t aggregate but defer” on now?

    I believe this may have been caused by having the “Aggregate all linked JS-files to have them loaded non-render blocking?” option checked on at the time.

    well, the Google Ads JS was inline and “also aggregate inline JS” was off, so don’t think that’s the reason.

    Thread Starter fabiocrispim

    (@fabiocrispim)

    These are the options I’ve currently got and are working with my Adsense units and hopefully Mediavine when they get back to me:

    Autoptimize options

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    looks like you also have “async javascript” active, which is overwriting AO’s “defer” attribute on the scripts with an “async” flag instead, but in most cases “defer” is the better choice so you might want to consider disabling “asyncjs” for now?

    and based on the pagespeed results, looking into “lazyloading” images might help a lot too. your theme (jnews) seems to load lazysizes but it does not seem to set the “lazyload” class on images so something’s off there. I see you’re also using Shortpixel (great), but in order to “properly size images” it might be worth giving “shortpixel adaptive images” (which uses the same image optimizing CDN as AO does) a try?

    Thread Starter fabiocrispim

    (@fabiocrispim)

    Thank you for your suggestions! I’ve deactivated async javascript for now, enabled lazyloading across the website, and have activated shortpixel adaptive images and that’s helped a lot for mobile speed, it’s now around 60. Will have a think about what else I can do to speed things up.Thanks again!

    Once I’ve heard back from Mediavine I’ll try enabling the other options in Autoptimize and see if it causes any issues with their ads.

    • This reply was modified 2 years, 11 months ago by fabiocrispim.
    Plugin Author Optimizing Matters

    (@optimizingmatters)

    you’re welcome, feel free to leave a review of the plugin and support here! ??

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Autoptimize option disables Adsense from appearing’ is closed to new replies.