how to use section targeting in google adsense to improve ad relevancy

Google Adsense uses various different techniques to match the ads from advertisers to the users. Section targeting can help your web site to display relevant ads to the user. In Display Networks, Adsense uses mainly three distinct ways of displaying the ads:

Interest Based: The ads are matched based on the interests of the user. This usually requires identifying the user and some user browsing history and is not directly related to the content of the page.

Placement Based: This gives advertisers the ability to bid and place specific ads in a specific slot of a website. Again, not a whole of relation to the content.

Context Based: This is based on the content of the webpage. The keywords you have optimized your webpage for will usually be useful here.

Usually the most used methods have been the contextual targeting and the main factor that influences this type of matching is the content of the webpage. Google as well as other search engine parses and indexes the webpage so as to match the users with the search query for the Search Network. In order to do this, the parser needs to identify the main content of the webpage.

In addition to what is considered the main content of the webpage, most pages also contain other information such as the sidebars, links to other sections of the website, comments etc. Most parsers usually do a very good job of identifying the main content. But sometimes depending on the page template or layout and the amount of the content in the pages, it could be difficult to correctly identify all the relevant content or just the relevant content.

As this information is also used to match the ads in a contextual way, it is important that the content is identified correctly. This allows for the most appropriate and relevant advertisements to be shown to the user. Furthermore, you might have optimized the content to the exact keywords that you want the content to rank for and it is important that the search engines identify these keywords correctly.

Showing the most relevant ads will arguably improve the Adsense Click-thru Rate (CTR) allowing you to generate more revenue.

Google provides an easy way for content publishers to specify the most relevant portions of the page content. This content will then be given higher weight when matched against the potential ads that are to be displayed. You can do this by surrounding your content with a specific XML comment tag that Google identifies while parsing.

It is usually best practice to use these tags on every page, especially if it is a blog. Blogs are notorious for having a lot of other content on the page in addition to the main content of the post. A big part of the page is the comments which can grow large over time. Often depending on the traffic and the popularity of the blog, the comments can grow to eclipse the actual content in size. These comments may not necessarily be completely relevant to the content itself.

As mentioned earlier, Google provides you with flexible markers or XML comment tags that you can use to mark off the relevant content on the page. This technique is commonly referred to as Section Targeting and this process marks certain sections of the content as relevant sections.

Emphasize Content

There are two tags that are used for this purpose as shown below. Your section should start with the first tag and end with the second one. Depending on the type and layout of the website, there are several different ways you can go about implementing them.

<!-- google_ad_section_start -->


<!-- google_ad_section_end -->

1. Use them as you write….

If the page contains static content and is a web page where the content is coded into the template itself, then you can insert these tags as you create these templates and content. If it is blog post, you can do this in the blog editor when you write the content.

Most blog editors will have a source mode where it should be able to insert these tags. Although there are a couple of gotchas you should be on the look out for, if you use this method.

a) Make sure that the tag is not visible in the blog post in visual (or WYSIWYG) mode.
b) Make sure that the editor does not remove the tag when saving, assuming that it is a comment tag and hence not required.

2. Blog Posts/Wordpress

If you have a blog, then you want the tags to be dynamically inserted into every blog post without having to insert them manually each and every time you create a post. Though the previous method works, it is very easy to forget to do them and double check each time a post is published.

If you are using a WordPress blog, then you can modify the theme files that act as templates. This will ensure that these tags are embedded everytime the page is generated. There may be several files that you will need to edit in this case depending on your theme. Some of the files to look for are index.php, single.php, page.php and archive.php.

Search for the PHP method the_content () in these pages. This is usually how the content will be displayed on the pages. Surround this method with the XML comment tags to implement section targeting.

<!-- google_ad_section_start -->
<?php the_content (); ?>
<!-- google_ad_section_end -->

The above list of files is based on a generic example based on how themes are generally written. If your theme is implemented differently, then you will need to track down where the content is shown and modify that file appropriately.

3. Plugins

If you are not proficient in html and editing the theme files on your blog is not your cup of tea, then there are some plugins that can help you out here, at least in WordPress. WordPress does have some plugins that allow you pick the content that should be emphasized using these Google comment tags.

Some of the plugins that can be used are Better Adsense Targeting, Google Ad wrap and Headspace2 SEO among many others.

The above tags show you how to emphasize the importance of a section. But you can also use the same section targeting technique to de-emphasize parts of the content.

De-Emphazing the Content

You can also specify sections that should be ignored or given less weight when displaying ads. This is usually not required if you have already specified which parts are important. But once in a while you might have some content on the page that generates ads that is not desirable for any specific reason.

In that case, you can use the following tags to specify that the specified content needs to be ignored. This is same as the earlier tag but with a new parameter (weight=ignore).

<!– google_ad_section_start (weight=ignore) –>


<!-- google_ad_section_end -->

While Google will take into consideration your suggestion, it does not guarantee that it will blindly follow your directions. This is due to the fact that these tags do have the potential to be misused just as keyword stuffing. Putting these tags around a bogus section, which has high paying ads but is completely irrelevant to the actual content of the webpage does not really work.


If you have modified the templates, as in the case of WordPress or another framework, then you should verify that the tags are correctly placed and that the correct content is emphasized. In order to do that, you can follow these quick and easy steps

  1. Open the webpage in a browser
  2. Right click on the page and look for an option which says something like “View Page Source” in the popup menu
  3. Click on the option and the HTML source opens up in a new tab or window
  4. Search this source for the text “google_ad_section
  5. Verify that the tags do show up in the code
  6. Verify that the main content of the page is actually between the instance of these two tags: google_ad_section_start and google_ad_section_end.

Section targeting when used correctly and judiciously, you might see a slight upward tick on your Adsense CTR and CPC. Don’t expect any huge difference in revenues, it is quite possible that Google was already doing a good enough job and this just helps to make sure that mistakes are made.