Google Ad Not Fitting in Nicely to Block and Has a Horrible Border, a Solution

Google Ad Not Fitting in Nicely to Block and Has a Horrible Border, a Solution

Sometimes, I use Google AdSense ads on my websites, and I noticed that some of the smaller ads when inserted into a bigger block, had a horrible border and in my opinion did not look nice.

This leads to a poor user experience.

A possible solution for this is outlined below. This worked for me. It may also work for you.

I use the WordPress platform. Go into your WordPress Dashboard, then Appearance, then Editor.

Then select the Stylesheet (style.css) file for the current active WordPress theme.

Then using the browser’s search function (In Microsoft’s Internet Explorer and Microsoft’s Edge product this is achieved by pressing the control key and F key at the same time).

Enter ins { as the search phrase to find.

Add CSS code to Ad

For me, I updated the information for the ins tag to the information highlighted in yellow in the image above. Then the Google adsense ad looks a lot better. It fits in nicely to the block, with the background now transparent. It now looks a lot better. More importantly for me, the horrible border has disappeared.

Happy days indeed. 🙂 🙂

Hi, I'm David. I write articles such as this one. Enjoy!

[More About David]

2 thoughts on “Google Ad Not Fitting in Nicely to Block and Has a Horrible Border, a Solution”

  1. Great quick guide for people who have the same problem with Google ad sense. A lot of times, many problems in WordPress can be solved by very simple coding work. But not everyone is familiar with this.

    Reply
    • Hi Farhan,

      You nailed it when you said that a lot of times, that problems in WordPress can be fixed with very simple coding work and that everyone is not familiar with this.

      Ideally you do not want to have to jump into the underlying code because WordPress, WordPress themes and WordPress plugins are being updated on a continuous basis.

      You have to remember to make the same ‘fixes’ again if the underlying code has changed as a result of an update.

      I recommend documenting them in some sort of soft document as the changes themselves involve small coding changes. However it can be hard to remember them all.

      Kind Regards,
      David

      Reply

Leave a Comment