localhost Configuration

This page explains how to configure Domain Mapping System on a local WordPress site with your localhost configuration settings.

For operating systems besides Mac OS and Windows, please utilize Google search for instructions about editing your Hosts file.

When building on a live website, domains must be configured on your server in order to map properly. This page explains the localhost equivalent when building a WordPress site locally.

Editing Hosts File on MacOS

  1. Open Terminal and input the following command to edit your Hosts file.

sudo nano /etc/hosts
  1. Scroll to the bottom of the file and add each domain or subdomain that you want to map. An example is provided here:

## DMS plugin mappings

127.0.0.1 your-first.domain.com
127.0.0.1 your-second.domain.com
127.0.0.1 your-third-domain.com
127.0.0.1 your-fourth-domain.com
127.0.0.1 your-fifth-domain.com

Editing Hosts File on Windows

  1. Press Start and find Notepad. Right-click to Run as administrator.

  2. Once in Notepad, go to File -> Open. Navigate to C:\Windows\System32\Drivers\etc and make sure to select All Files to open/edit the hosts file.

  3. Scroll to the bottom of the file and add each domain or subdomain that you want to map. An example is provided here:

## DMS plugin mappings

127.0.0.1 your-first.domain.com
127.0.0.1 your-second.domain.com
127.0.0.1 your-third-domain.com
127.0.0.1 your-fourth-domain.com
127.0.0.1 your-fifth-domain.com

Last updated