How To Properly Test Your AdSense

It's been only few days ago when I felt the need to experiment more with AdSense ads formats on my local server, and I couldn't find a way of doing it without breaking the terms and conditions: they strictly prohibit showing AdSense blocks on your temporary/internal pages which are "under construction", and even more strictly prohibit clicking on your own ads.

Luckily, I've read a recent post by Thilak of TechBuzz: Running AdSense Ads in Test Mode, and it motivated me to find out more about the topic of testing AdSense.

I ended up sending an email to the Google AdSense support team, and they confirmed once again that this solution is absolutely correct and valid:

All you have to do is add google_adtest = ‘on’; to each AdSense block you're testing on your website. It will still show all the ads, but will ignore any clicks on your part until you remove this test option from your code. It is allowed to change the AdSense block source code to add this line, so you will not violate any terms or conditions.

This is how your code might look (I've obviously blanked the ad client ID of mine: 

<script type="text/javascript"><!–
google_ad_client = "pub-xxxxxxxxxxxxxxxx";
google_adtest = ‘on’;
google_alternate_color = "FFFFFF";
google_ad_width = 728;
google_ad_height = 15;
google_ad_format = "728x15_0ads_al_s";
google_ad_channel ="9517067767";
google_color_border = "FFFFFF";
google_color_bg = "FFFFFF";
google_color_link = "336699";
google_color_text = "000000";
google_color_url = "336699";
//–></script>

Yep, it's that easy. Enjoy!

Comments

  1. Thanks for featuring me of this blog ;)

  2. You’re welcome, Thilak!

    Thanks for your original post, I found it very useful.

  3. Wow, a neat trick. Finally a fix to the accidental clicks on my own site.

Speak Your Mind

*