Open Terminal and to open the hosts file, enter the following command:ģ.
Cmd+spacebar to open Spotlight and search for TerminalĢ. The steps below outline how to change your hosts file in order to view a website located on a different server than the live version.īelow is a quick reference on how to go about editing your ETC / Hosts file in Terminal (Mac):ġ.
From time to time you may find that you need to view a website that is hosted locally.įor instance, when conducting page load speed tests for a client, we first created a copy of their website on our servers to test the differences in the hosting resources between the two servers to determine if changing hosting providers might positively increase their site’s overall speed.