I’ll be the first to admit that I’m no legendary hacker. In fact most, if any, hacking that I do involves finding work-arounds to buggy or rigid software. Which in a way (jokingly…kind of) is what I’m about to show you in this post.
Many software cracks usually allow you to run an application which edits your hosts file, effectively blocking your computer from accessing the software’s registry (or any other identification) server. However, some of these hosts-patching applications have problems doing their job. Some will actually alter your hosts file in a way that can harm your computer.
Luckily, you can patch the hosts file yourself. As long as you know the URL of the site you wish to block or redirect, it’s really not that difficult or challenging at all.
Modifying the Hosts File on Windows 7
- Click on Start (Window button)
- Click on Computer
- Navigate through Windows Explorer through these folders:
- C:/ (or whatever drive you have Windows installed in)
- In the “etc” folder, select the hosts file and copy and paste it to your desktop.
- Open the hosts file on your desktop, selecting to open through Notepad.
- Make modifications to the file in Notepad.
- Save using Ctrl+S.
- Drag and drop the hosts file back into the “etc” folder
- Select “move and replace file” to overwrite the original hosts file.
Originally, your hosts file should look something like this:
How to Block Websites
Making the proper edits on your hosts file to block a website is simple. Just add the following to the bottom of the hosts file in Notepad:
So if I want to block Myspace.com, I would then type:
So now if you try to type myspace.com into a browser or click a link to myspace, you will run into this:
Lots of people edit their hosts file to simply block bad or unwanted websites that could harm their computer. Here is along, extensive list of bad websites that are already styled to be blocked in your hosts file. Just download the text document, copy the blocked website codes, and paste it into your hosts file as I directed above.
One concern with using long lists like this that are designed to patch your hosts file is that they could manipulate the file to forward you to unwanted sites. Make sure that all websites are preceded with the code: 127.0.0.1. That code is the IP address that defaults to nowhere, a blank page. If there is any other IP address in the code, I wouldn’t trust it as it could direct you to sites with viruses loaded up and ready to take your computer or log your keyboard.