127.0.0.1 example.com
For example, showing the computer will block facebook.com access and example.com.
Block the website by hosts files on Windows 8 Picture 9
Save the file after it's done. These changes will be applied immediately and the website will be blocked without restarting the system or browser.
Block the website by hosts files on Windows 8 Picture 10