How do I edit the HOSTS file and other system/administrative files using NOTEPAD?

When using notepad to edit the HOSTS file or any other administrative or system file, you will get an access denied error when trying to save the modified file.

To successfully edit an administrative file, you must open notepad "as administrator."

  • Click start
  • Type: notepad
  • Right-click notepad
  • Click "Run As Administrator"

After you have opened an "administrator" notepad, you may open and edit administrative files.