Setting up domain with WordPress


Looking at DigitalOcean for hosting my WP Site. It’s the cheapest but I am a bit of a noob so sorry if this is a really dumb question.

Once I’ve migrated my site, and it’s on the IP I get for my droplet and I am ready to go live and switch hosts. I then go into networking, put it in, and then put the details in on my website etc.

Do I just set the WordPress Address (URL) and Site Address (URL), to my domain and it should work from there?


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

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.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.


Before making the DNS change I would recommend testing your website with your hosts file.

You can edit the hosts file on your PC to bypass the DNS lookup and access the site on your Digital Ocean server through your main domain rather than the droplet’s IP address.

This only affects your PC and visitors to your website will see the site as normal.

The location of the file is as follows:

Windows PC c:/windows/system32/drivers/etc/hosts

Mac OSX /private/etc/hosts

Linux /etc/hosts

Just open it up in your favorite text editor (e.g. Notepad) and add that line on the bottom:


Make sure tho change the Your.Droplets.IP.Address with the actual IP address of the droplet and the part with your actual domain

Once you have made the change, save the file then clear your browsers’ cache and browse to your website as normal.

You will see it served from our systems and will be able to test the full functionality of your Wordpress site.

To view the site on your existing host, just remove the line from your hosts file. If everything is working as normal, then you can proceed with the DNS change and point your domain to the Droplet’s IP address.

Also I would recommend following this step by step guide on the Digital Ocean website on how to migration your website with zero downtime:

Let me know if you have any questions. Bobby