Question

Digital Ocean Wordpress One Click Install - How can we change the domain name once initial setup has been done

Posted July 4, 2020 286 views
WordPressDigitalOceanDigitalOcean 1-Click Apps Marketplace

Digital Ocean WordPress One Click Install - How can we change the domain name once initial setup has been done?

While initial setup - used different domain name just to set and test site. once, all done - how can we update the domain name. tried to update sit…

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.

×
1 answer

Hello @er.tejaspatel88,

In order to make that change, there are a couple of things that you need to change:

  • First login to your WordPress admin panel, then go to Settings -> General and change your WordPress Address (URL) and your Site Address (URL) to your new domain name. Finally, save the changes.

  • Then you need to SSH to your Droplet and change your Apache Virtual Host:

  • sudo nano /etc/apache2/sites-enabled/000-default.conf

In that file change the ServerName and the ServerAlias with your new domain name.

After that save the file and restart Apache in order for that change to take effect:

  • sudo systemctl restart apache2

Hope that this helps!
Regards,
Bobby

Submit an Answer