Wordpress Multisite Domain Mapping


I’m trying to set up a multisite install with domain mapping. I have everything up and running but on the mapped domain all of the theme asset urls look like


instead of


I’m not entirely sure how sage changes wordpress urls in relationship to the plugin. Any insight on how I can fix this would be much appreciated

Any help on this would be greatly appreciated

Are you using Soil?

20 char

I have tried with Soil activated and deactivated. I am using the WPMU Domain Mapping Plugin by WPMUDev.

Without soil, I get

<link rel='stylesheet' id='parent/css-css'  href='//mysite.com/themes/themename/dist/styles/main-38fdacf443.css' type='text/css' media='all' />
<link rel='stylesheet' id='child-style-css'  href='//mysite.com/themes/themename/style.css' type='text/css' media='all' />

When I access the mapped domain via subsite.mysite.com everything works perfectly.

I’m not sure why the ‘/app’ part is being removed from the URL. I have tried searching through the plugin to figure out what it’s doing, but I’m still not sure

So I had to edit config/application.php.

I changed




Everything appears to be working, and I also have soil relative urls activated.

Any idea how this change could negatively impact my site?

Hey @DemaniClassic DId you ever run into an issue with domain mapping redirects not letting you log in the the mapped domain? We used your fix (thanks for that!) but are now getting a redirect loop when trying to access the domain via mappedexample.com/wp/wp-login.php. The only way that we can currently allow the client to log in is through the main sites’ login page.

Did you run into this issue as well? We’re also using this plugin for domain mapping: https://premium.wpmudev.org/project/domain-mapping/

Anyone’s help on this would be greatly appreciated!

  • Daniel
1 Like

Hey daniel

I switched over to Mercator a few days ago. It’s much smaller than the plugin by wpmudev.org, and it’s free.

I did not encounter your problem because I wanted everyone to log into the main site. If someone typed mappedexample.com/wp/wp-login.php they would be redirected to my main login and then directed to the proper dashboard.

I am still testing Mercator. If it fixes your issue, I’ll refresh this thread with my setup steps once I’ve finished.


Curious how you handle updating nginx config when adding a new site…and how you keep your trellis hosts configuration up to date as well.

If the main benefits of trellis are reproducibility and disposability it makes sense to keep the configs in sync.

Whenever I add a new site to a MU environment I either need to add the confs to trellis and re-provision or manually change nginx confs

I did manage to find part of solution for dealing with DNS configuration (a cloudflare ansible

Running into this same issue with wmpudev’s domain mapping. It strips out the /app from the url. I also need to allow them to log into their own wp-admin via their url.

Anyone find a solution to this?

Have you tried this? Multidomain multisite without a domain mapping plugin