Hi,

I have a wordpress website, let’s say mainwebsite.com and have installed Wordpress Multisite on my “Ubuntu WordPress on 18.04” droplet, using a subdirectory like so: mainwebsite.com/website1.
I would like mainwebsite.com/website1 to become website1.com (I already bought it from Namecheap) .
How can I achieve that?

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
Submit an Answer
2 answers

Hi @worldwade,

You’ll need to do an internal transfer between your domains. Basically, WordPress stores your domain - mainwebsite.com in your database, you’ll need to find every occurrence and change it to website1.com. I believe there are some plugins that can help you achieve that.

After a quick search I found the following plugin that I believe can help you achieve that : Velvet blues update urls. Please note that I haven’t used this plugin and it would be best to create a backup prior to beginning this operation.

If you don’t want to use a plugin but do it manually, a quick search for ‘WordPress change domain name’ in Google should help you find some relevant articles. They are quite long and that’s why I’m not quoting them here.

Regards,
KFSys

Hi, thanks for your answer.

I installed WordPress Multisite on mainwebsite.com (main) and created a subdirectory site like so:

– mainwebsite.com (main)
– mainwebsite.com/website1 (second)

On DigitalOcean, I connected a new domain (website1.com) from Namecheap like so:

– A RECORD, @, IP of mainwebsite.com
– A RECORD, www, IP of mainwebsite.com

On Namecheap, I connected the DNS like so: ns1.digitalocean.com (and ns2 and ns3).

I went to Dashboard > Sites > mainwebsite.com/website1, and changed to this:

Site Address (URL): https://website1.com.
SiteURL: https://website1.com
Home: https://mainwebsite.com/website1

When I go to website1.com, it only redirects to mainwebsite.com, not even to mainwebsite.com/website1

How can achieve this: website1.com/wp-admin becomes mainwebsite.com/website1/wp-admin. (complete “replacement”, not just a redirection)

I hope this helps more. Thanks again!!