How To: Remove all ads from all sites

Sep 1, 2009

Almost every page today has got ads these days and most of them are powered by Google Adsense, Adbrite, Chitka etc...

I remember from the day I started using Internet from that day I hated these ads a lot, as they always redirect me to somewhere else and then I just roam here and there in between the ads.

I have found a lot of scripts addons to stop these ads for Firefox, Intenet Explorer, but never found any universal way to do that. One day I was reading some of my old articles and I found this How to: Block a website. This remind me of my tweaking days, so I taught why not try to remove ADs by using this technique.

First you need to know What is Windows Host File

The Windows Host File is a computer file used by an operating system to map hostnames to IP addresses. The hosts file is a plain-text file and is traditionally named hosts -WikiPedia

This file contains the mappings of IP addresses to host names. Each entry should be kept on an individual line. The IP address should be placed in the first column followed by the corresponding host name. The IP address and the host name should be separated by at least one space.

Additionally, comments may be inserted on individual lines or following the machine name denoted by a '#' symbol.

# # source server

So by now you must have get an idea what is an Host file. You can view your Host file at C:\WINDOWS\SYSTEM32\DRIVERS\ETC > HOSTS.

Well there are a lot of uses of HOSTS file but in this tutorial I am concentrating on how to block ads using this host file. This is done by using a dummy address, or local host address typically, (which is in fact the address of your machine locally that's why it is called Local Host). For example, consider this entry:

If this entry is saved in your host file then any reference to will be redirected to your own computer, and thus you are not able to visit

By further advancing this technique of blocking a site we will remove ads from all pages, lets know how. Now all you have to do is just follow these steps-

  • Open HOSTS file in Notepad
  • and after the line localhost
  • Copy the following lines and save the file.

#FASTCLICK #[] #[Panda.Spyware:Cookie/FastClick] #[Tenebril.Tracking.Cookie] #[]
#BLOGADS #[WebBug] #[WebBug]
#ATDMT #[McAfee.Cookie-Atdmt][Google.Diagnostic]
# #[disabled affects MS downloads] #[] #[] #[] #[EventTracking] #[] #[]
# #[disabled affects Hotmail signup] #[eTrust.Tracking.Cookie]

These lines are sufficient to remove all types of ads from all sites you visit, but in case you think it is not sufficient visit the following link and copy paste it to the host file.



ramaraobobby said...

cool trick... thank for sharing..

kelly said...

Love yr tips and now, showing some love to your GREAT blog! :)

Anonymous said...

Worked a treat thankyou

Post a Comment


Connect With ME