Today I’ve got a tutorial to show all of you WPMU DEV members how to use our domain mapping plugin. Domain mapping lets you map any domain onto your WordPress network, giving you the ability to offer domains to your network users.
So this:
http://mynetwork.com/networkuser
becomes:
http://www.networkuserdomain.com
The process can feel a little complex if you’re not familiar with fiddling around in your CPanel and playing with IP addresses. But it’s actually remarkably simple and after you’ve gone through it once you’ll be mapping domains all over the place.
Before we get started, here’s what you need:
- A dedicated IP address. This means that the domain will be mapped onto a single IP. If you’re using shared hosting without a dedicate IP, your IP address will change pretty regularly. This means that there is no single IP for your domain to be mapped to. Contact your host and ask them to add a dedicated IP to your account – this may come as part of your hosting package or you could be charged a small fee.
- Access to CPanel
- A domain to map and access to its settings
- The WPMU DEV Domain Mapping Plugin
- WordPress Multisite install
If you’re a fan of learning by watching rather than reading, you can watch this video made by Mason who goes through all the steps for setting up domain mapping.
WPMU DEV Domain Mapping from Zebedee Films on Vimeo.
Here we go.
1. Set up your domain
I have a domain set up at Godaddy that I’m going to map onto another site. I need to point this to my dedicated IP address.

Login to your domain registrar and find the area that lets you change these settings. At Godaddy it is called “DNS Manager.” There you will find a record under A(Host) with @ pointing to an IP Address. We want to change this.
Click edit and insert your dedicated IP.

2. Park Domain
As my multisite is on shared hosting I’ll need to park the domain. To do this log into your CPanel and scroll down to “Parked domains”
Click Parked Domains and input the domain you want to park.
Now we get to play with WordPress!
3. Create a new site
Log in to your network admin and add a new site:

I’m going to call mine domainmap
Here it is:

4. Install Domain Mapping
Download Domain Mapping and open up your site in your favorite FTP program. You need to install the components of the plugin in a few different folders. Let’s do these one by one:
a) Copy domain-mapping.php to the mu-plugins folder
b) Copy the sunrise.php file to the wp-content folder

c) Open wp-config.php and add the following line before /* That’s all, stop editing! Happy blogging. */
define( 'SUNRISE', 'on' );

5. Configure Domain Mapping
Log back into Network Admin dashboard and go to Network>Network Settings

Scroll down and you will find your domain mapping configuration. Here you need to add your dedicated IP.
Save
6. Map Domain
Go to the dashboard for your new site:

Scroll down to Tools > Domain Mapping

Add the domain that you want to map:

Click Add
7. Visit

There it is!
And don’t forget, you can use the WPMU DEV Supporter plugin to offer this as a premium service to paying members. In the next few weeks I’ll look at some of the awesome things you can do with the supporter plugin.
The WPMU DEV Domain Mapping plugin is available now for members – non-members can sign up or buy a copy for $39.
Very nice detailed tutorial, I was looking for this and was having a difficult time mapping domain, I have mapped one now with this tutorial, thanks
Thank you for the tutorial. My hosting company preferred not to give an IP and so they took care of the alias to the main site. However, the WPMU dev plugin wasn’t doing www … maybe there is a trick to that and could be explained in the tutorial.
Step 2 explains how to setup the Domain Map on a shared hosting environment. What about for a dedicated hosting environment? Do we need to park the domain or skip this step? Thanks.
@Eli Just wanted to let you know that I am checking with the dev about this and will let you know asap.
@LPH Your hosting company won’t give you your IP? That is really odd – you should check with them to make sure that you have a dedicated IP. Also, you need the IP address to insert into the domain mapping plugin or it won’t work.
The host I’m using for a new project is currently refusing to grant me an IP address even though ihave “2″ in the package I bought.
They say..
“justification provided is not efficient enough for ARIN to allow this to be allocated to you”
Any suggestions? New host?
That’s insane! I would move to a new host.
You are right, it is totally insane. I set up the project with a new host, having become a little frustrated with my current one. But now I think I’m better off with my existing host. Time to switch back.
Hi
Yes. There is a dedicated IP but this is not a static IP, therefore the safest was for the host to map as alias then the mapping plugin takes care of the subdomains.
The IP is not required in this way.
@Eli – yes, you should still park your domain using CPanel. Hope that helps :)
Trying to park the domain (as per step 2)
I get the following error – I assume because I have them setup in the same reseller account – Any ideas??
Error from park wrapper: domain.com is already configured. Sorry, that domain is already setup (remove it from httpd.conf)
Very nice detailed tutorial. it so nice for me
thank
Doesn’t work for me – host tried for weeks to sort domain mapping 3 months later still displaying my muinstall domain
This can also be done without A or CNAME records by changing the DNS in the mapped domain to the nameservers of the Multisite install.
You’ll still need to park the mapped domain name in the CPanel of the multisite domain, but this gets around the need for a dedicated IP (although, technically that’s what the nameservers are doing for you).
Well written tutorial with great pictures to follow along. Even a newbie should be able to do this. Good job!
~Question related to DomainMapping~
Plugin: WordPress MU Domain Mapping
Currently I am in situation as below,
*exampleB.com is not my primary domain.
I have an addon domain exampleB.com installed with multisite
/public_html/exampleB.com/(WordPressMultisiteFiles)
Can DomainMapping function in such condition?
I tried with ParkedDomain and also AddonDomain for exampleC.com(Domain for Mapping), doesn’t seem to function.
Where and How should I point exampleC.com to ?
So you’ve gone through setting up WordPress Multisite, and now you’re ready to start setting up new sites in your network.The Only trouble is, you want to use unique domains for your sites instead of using sub domains of your main installation. Well, with a little extra effort, it’s entirely possible. Read More