Windows: Configure Static Host Name to IP Address Mappings

Posted September 16, 2003 by Quinn McHenry in Windows

Last Updated on

Using the hosts file, ip addresses can be mapped to hostnames. This is useful to access systems that do not have a DNS entry and for test and development purposes.

The hosts file exists in the SYSTEM32\DRIVERS\ETC directory under the Windows root directory (i.e., \WINDOWS or \WINNT). Edit this file and add a line like the following: testserver

This would map two names to the ip address, testserver and

For most installations of Windows including XP, Vista, and Windows 7, the location of the hosts file is the following:


About Quinn McHenry

Quinn was one of the original co-founders of Tech-Recipes. He is currently crafting iOS applications as a senior developer at Small Planet Digital in Brooklyn, New York.
View more articles by Quinn McHenry

The Conversation

Follow the reactions below and share your own thoughts.

Leave a Reply