Netlify Custom Domain and WordPress

Hi @songfarm-david, sorry you’ve been waiting so long for a reply!

What I would do in your position is create a subdomain to point to Server A. Since you’ve pointed your domain nameservers to Netlify, that should mean that you’re using Netlify DNS management, which you should find under the Domains tab at the top of your team site list.

Add a new record with your chosen subdomain in the Name field (replacing the @). For example, you could enter wp to get the subdomain wp.yourcustomdomain.com. Point that record to Server A (using whatever DNS settings that server requires).

Once you do that, after DNS propagates, you should be able to go to yoursubdomain.yourcustomdomain.com/wp-admin and access your WP admin.

If you really want to get fancy, you can add a couple of proxy redirects so it looks like you’re working in one seamless site. (This can also avoid potential CORS issues if you’re accessing your WP API using JavaScript.)

To do this, create a file called _redirects file in the base of your published site. Add two lines to that file:

/wp-admin     https://yoursub.yourdomain.com/wp-admin    200
/wp-json      https://yoursub.yourdomain.com/wp-json     200

With that in place, you can go to yourdomain.com/wp-admin and access your WP admin as if it’s part of the same site. Something extra nice about this is that you can change the first /wp-admin path to anything you want, for example:

/doorbell     https://yoursub.yourdomain.com/wp-admin    200

Then you’d go to yourdomain.com/doorbell to access your admin. You’d be amazed how many requests our servers get for wp-admin paths on our customers’ sites, even though we can’t even host WP sites! Hackers just keep trying anyway. Changing your admin URL just makes things one step harder for someone to hack your WP admin.

Hope that helps!

3 Likes