The HOSTS file is where your computer goes first to translate a domain (404TechSupport.com) to an IP address (96.30.24.98). It’s mostly been replaced by the use of DNS because it would be impossible to keep up with all the new websites created or server changes that occur daily. Despite that, it still has its uses for correcting something locally or filtering sites. Malware might also find its useful to redirect web traffic to a different server. For that reason, Windows has tightened up security on the file and editing the file requires a little trick.
If you were to just go to C:WindowsSystem32driversetc and open the hosts file in Notepad, you wouldn’t be able to save your changes.
Instead, you need to go under the Start Menu and either type Notepad or find its listing. Then right-click on Notepad and choose to ‘Run as administrator’. A prompt should come up and you can give it permission.
Once Notepad open go to File, Open (change file type in the dialog box from .txt to all files) and browse to your HOSTS file. You’ll then be able to make and save changes as needed.
Upon restarting the computer, you may receive a message from Windows Defender noticing a difference to the HOSTS file. Since the HOSTS file might have been changed by malware, it assumes you didn’t do it. You can disinfect it to revert the HOSTS file back to the default file or tell it to ignore the SettingsModifier:Win32/PossibleHostsFileHijack. However, if you didn’t change the HOSTS file – you probably want to disinfect and clean the system.
TL;DR – Run Notepad as an Administrator (even if you are using an administrator account), open the HOSTS file, and save your changes. Confirmed by a Microsoft Support KB article.