This was pretty much the best way to do it pre-Ad Block. I recall doing things like this in the late 90s and it worked rather well.<p>One of the caveats to this method is that it can limit you from accessing some CDNs.<p>MVPS Hosts is worth a look:
<a href="http://winhelp2002.mvps.org/hosts.htm" rel="nofollow">http://winhelp2002.mvps.org/hosts.htm</a><p>Also another solution from the early part of 2000s was to use Proxomitron:
<a href="http://www.proxomitron.info/" rel="nofollow">http://www.proxomitron.info/</a><p>It was handy because it was basically Greasemonkey in the form of a proxy server. However, it is no longer maintained and the original author has since passed away.