How to Remove Yellow Border Around Adsense Ads ?

adsense with yellow border

Have you noticed a yellow border box around Adsense Ads? What do I do to remove the yellow box (border) that is visible after Adsense Ads begin to appear? That is obvious questions for newbies.

Introduction

  1. If you are getting only yellow boxes and no ads means your Adsense application is not fully approved or it will take a few more days to complete the procedure.
  2. If you are getting yellow border with ads then you should read this post.

yellow border on adsense ads

Why it happens?

  1. Logical Reason: – Google Adsense algorithm decides which ad to display where based on its revenue calculation. It is possible that 90% of your space will be shown as yellow if it think that small ads can perform better there. After all what Adsense matters are revenue irrespective of banner size.
  2. Coding Reason :- Your ad code looks like this
*************************Ad code*********************
<ins class="adsbygoogle"
     style="display:block"
     data-ad-client="ca-pub-3705195732142517"
     data-ad-slot="7619782387"
     data-ad-format="auto"></ins>

And your theme css code has following line of code:-

*****************************css********************
ins {
	background: #fff9c0;
	border: none;
	color: #333;
	text-decoration:none;
} 

 

Clearly CSS added for ins has background: #fff9c0. This is the sole reason for white backgrounds. Do not change this, Rather add few more lines to your CSS as stated below.

How to Remove Yellow border for Adsense Ads ?

  1. Go to Admin Page of Website-> Appearance -> Editor -> Stylesheet(style.css)
  2. Add below code in css.
  3. Save style.css
  4. Reload post and yellow border gets disappeared.





.adsbygoogle {
background: #FFF;
}




What it does?

We basically add a white background (#FFF) here and style the class .adsbygoogle rather than the ins tags which might actually need that yellow background color somewhere. You can change the background to whatever color your background is.

Now your Ads looks like

adsense without yellow borderHope it solve your problem. Comment if still have any issue and subscribe us.
More post related to wordpress

One thought on “How to Remove Yellow Border Around Adsense Ads ?

  1. I’m not sure why but this blog is loading very slow for me. Is anyone else having this problem or is it a issue on my end? I’ll check back later on and see if the problem still exists.

Leave a Reply

Your email address will not be published. Required fields are marked *