A new feature from the Google AdSense ads team, the ability to have very or slightly rounded corners on the borders of your Google AdSense Ad units.

Have changed the Talian 5 WordPress AdSense theme to use very rounded corners and I like it, so have updated all my WordPress AdSense themes to have the option of using/not using very/slightly rounded corners and have sent out an update to all WordPress with SEO/AdSense themes customers for free (all themes updated and working with WordPress 2.5+).

What’s a Rounded Google AdSense Corner?

AdSense Slightly Rounded CornersAdSense Rounded Corners
Not got a clue what a rounded corners ad looks like, well the image to the left is what an AdSense Slightly Rounded Corners ad looks like and the image to the right shows an AdSense Rounded Corners ad unit.

Note image ads currently show as square borders.

Now you know what a rounded corner ad is I bet you want to know how to add them to your website :-)

If you run a WordPress blog easiest way is use a WordPress with AdSense and SEO optimization theme like Talian 5.5 from this site and by default you’ll have rounded corner ad borders on all ads whilst having the easy option of changing to slightly rounded or square borders by making a small change to one file in a text editor (or through the WordPress theme editor).

Want to add the code to another WordPress theme, read on.

Make a New Rounded Corners AdSense Ad Unit

One option is to log into Google AdSense and create a new ad unit with very rounded or slightly rounded borders. Not sure when they made the change I saw the other day, but they no longer list all the code responsible for creating a Google AdSense ad unit. Instead you get something like this-

<script type="text/javascript"><!--
google_ad_client = "pub-###########";
/* 728x90, created 12/04/08 */
google_ad_slot = "########";
google_ad_width = 728;
google_ad_height = 90;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>

Basically they are storing most of the information on their system, there are benefits and disadvantages to this setup. For most people will make updating a website easier, add this sort of code to your website and rather than editing your website when you want to change the look of an ad unit, login to Google AdSense and edit it there and your site will show the new options you just added. Well to be precise you can edit everything except the dimensions of the ad, so the one above will always be 728×90 leaderboard ad.

This is terrible for people like me however who like complete control over their AdSense code and develop WordPress AdSense themes. If I added the above to one of my SEO/AdSense themes it would only work for me! Fortunately the old AdSense legacy code formatting still works (still works in 2014), so after a Google search or two I found what I needed to update the old AdSense coding to use this new feature.

Editing Legacy AdSense Ad Unit Code to use Rounded Corners

To add rounded corners to your old AdSense coding add one of these lines of code to your existing AdSense code.

For very rounded corners add-

google_ui_features = "rc:10";

For slightly rounded corners add-

google_ui_features = "rc:6";

For square corners add (or don’t do anything as it’s the old default look)-

google_ui_features = "rc:0";

So you have something like this-

<script type="text/javascript"><!--
google_ad_client = "pub-8325072546567078";
google_alternate_ad_url = "";
google_ad_width = 250;
google_ad_height = 250;
google_ad_format = "250x250_as";
google_ad_type = "text_image";
google_ad_channel = "";
google_color_border = "9ACA3C";
google_color_bg = "FFFFFF";
google_color_link = "000000";
google_color_url = "FFC12B";
google_color_text = "000000";
google_ui_features = "rc:10";
//--></script>
<script type="text/javascript"
  src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>

The code above is used on this page, the 250×250 main content ad unit at the top of the content offset to the right. Save and upload and you’ll have very or slightly rounded corners for all text based ad units.

Will be interesting to see how this impacts AdSense revenue.

David Law

David Law > AKA SEO Dave
*
: 20+ Years Experience as a Freelance SEO Consultant, WordPress SEO Expert, Internet Marketer, Developer of Multiple WordPress SEO Plugins/SEO Themes Including the Stallion Responsive Theme.

Website - SEO Gold