Editing Your Host File

For various reasons it may be necessary to update the hosts file on your computer to properly resolve a website by its domain name. The most common reason for this is to allow people to view or publish web content immediately after purchasing a new domain name or transferring an existing domain name to a Fpweb.net Hosting service.

New and transferred domain names have a delay period that can be anywhere from a few hours to a few days. During this period of time the new or transferred domain information propagates around the internet, and is generally unavailable.

If you need to update your site immediately and cannot wait for the propagation of domain information around the internet, you can edit a file on your computer as a temporary work around.

Please note: this work around is only valid on the computer on which the change was made. It will notmake the website available to anyone on the internet.

Step-by-step Procedure

Windows operating systems contain a file called ‘hosts’ that will force resolution of your domain name.

  1. Open the hosts file
    1. Go to the Start menu and choose Run. Type the following in the Run dialog box: Edit Host File
      1. For Windows NT and Windows 2000
        1. C:\winnt\system32\drivers\etc
      2. Windows XP, Windows Vista or Windows 7
        1. C:\Windows\System32\drivers\etc
    2. Click the OK button

      (This should open a window with several files in it.)

    3. Find the file called ‘hosts’ and double-click it. If prompted, specify that you would like to choose a program to open the file with from a list of programs.
      1. Choose ‘Notepad’ from the list of available programs.
  2. Edit and save the hosts file
    1. The contents of your hosts file should look something like this:
      sample hosts file thumbnail
      Sample Hosts File #1 (click to enlarge)
    2. Start typing on a new line at the bottom of the file.
      1. To do so, place your cursor at the very end of the last line and hit ‘Enter’ to start a new line.
    3. Type these two lines of text like this example:

      (use your server IP address and your site domain in-place of the defaults below)

      1. 123.123.123.123    yourdomainname.com
      2. 123.123.123.123    www.yourdomainname.com
    4. Your hosts file should look something like this when you are done:
      sample hosts file thumbnail #2
      Sample Hosts File #2 (click to enlarge)
    5. Close the hosts file and save it when prompted.
    6. PLEASE NOTE: At this point you should be able to view and publish to your website using your domain name. After 3-4 days, you will want to undo this change to your hosts file so that you can check to see that your domain name is now resolving without assistance over the internet.
  3. Undo the Hosts file change

    (after you have confirmed that it is resolving properly)

    1. Open the hosts file as described above.
    2. Delete the information that you added previously and close the file.
    3. Choose to save the changes to the hosts file when asked.

Fpweb.net has been a trusted hosting provider for over a decade.

Looking back, we’ve been hosting Windows Server Websites since 1996 – in Internet time, that’s an eternity. Simply put, managed hosting on shared, virtual and dedicated servers is our specialty, and our passion. Make the same great decision that some of the world’s largest companies have already; Host your Website with Fpweb.net – our expertise makes all the difference.

World-class support from America’s largest Microsoft® Gold-Certified staff of engineers.

Experience On-demand Expertise® and Total Care® from the most experienced experts in Windows Hosting. We provide hosting for thousands of customers in more than 100 countries. Our Windows Web hosting platform has been a rock of stability, reliability, security and ease of use for longer than most hosting companies have been around. Let us show you why we are the expert provider of managed hosting solutions and support for ASP, ASP.NET, SQL Server, mySQL, VisualStudio.NET, DotNetNuke, SharePoint Hosting, SharePoint 2010 Hosting and MOSS Hosting.