How to Hide AdSense Ads on Blogspot Blogger Search Pages

How to Hide AdSense Ads on Blogspot Blogger Search Pages

One reason AdSense sites are banned most often is because AdSense ads appear on search pages.


There are two reasons why the appearance of AdSense ads on the search page is the cause of the site being banned.

1. Because there are fraudulent visitors who type in inappropriate keywords in the search field.


When a visitor types in inappropriate keywords in the search field and clicks on the "Search" or "Search" button on your blog, your blog will generate more or less URLs like this:

https://kidsstory.blogspot.com/search?q=story+adult+hot

story + adult + hot is the inappropriate keywords that casual visitors are looking for.

Now, when the URL is detected by AdSense, AdSense will consider your blog as an Adult Story blog, even though it is actually a children's story blog.

2. Because the search page has no content.


The second reason is because the search page has no content when what the visitor is looking for through the search column is not found.

If a search is not found, usually the search page will only appear like this:

No posts match the query: how to get rich quick. Show all posts

Posts like that can not be referred to as content, for AdSense that page is strictly forbidden to advertise AdSense.


How to hide AdSense ads on Search Pages.


If your blog doesn't want to be banned for the reasons I've written above, get rid of AdSense ads on the search page now.

The following is how:

For those who use HTML / JavaScript Widgets:

1. Look for the HTML / JavaScript widget ID that you use to install the AdSense ad code.

How: go to Layout, click edit on the HTML / JavaScript widget that contains the ad code, widget ID will appear at the very back of the URL.

How to Hide AdSense Ads on Blogspot Blogger Search Pages


2. After knowing the widget ID, then enter the Theme menu, Edit HTML, click "jump to Widgets" and select the widget ID that was known earlier. For example HTML1 ID:

How to Hide AdSense Ads on Blogspot Blogger Search Pages


3. At the bottom of the code <b: widget id = 'HTML1' ........ Look for the code <b: includable id = main'> after that paste this code below:

<b:if cond='data:blog.searchQuery'><b:else/>
4. Scroll down a bit, look for the code </ b: includable> after that add this code on it:
</b:if>
5. Later the results will be like this:

How to Hide AdSense Ads on Blogspot Blogger Search Pages



What I marked the arrow was the code that was added.

6. Click "Save theme"

7. Oh yes, if you install more than one ad code, then edit them all one by one.


1. For those who install the AdSense ad code directly in the template, just put this code before the ad code:
<b:if cond='data:blog.searchQuery'><b:else/>
And put this code after the ad code:
</b:if>
2. The end result will be more or less like this:
<b:if cond='data:blog.searchQuery'><b:else/> 
... the adsense ad code here ... 
</b:if>
That's how to hide AdSense ads on search pages on blogger or blogspot.
The method above is actually not hiding AdSense ads, but rather eliminating AdSense ads on search pages. So we can be sure 100% safe.
Hopefully implementing this method will make your blog safer from being banned.