How can I add subdomain as alias in digitalocean?

I have droplet with wordpress on DO. Also I have cloudfare A type record as (ip is droplet ip). It working well but I want adding new alias as If user enter he get my WP site as hi enter I added in cloudflare A record for (ip is droplet ip) and added in DO networks new A record for But is redirected to What I am doing wrong?

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.


There are a few things that I could suggest here:

  • If you are building a separate website for your reviews subdomain, I would recommend creating a new Apache Virtual Host so that the reviews subdomain could have its own document root and Apache configuration. You can follow the steps on how to do that here:

  • In case that you want the reviews subdomain to share the same files as your main website, for example, you would need to do that if you are building a WordPress Multisite. Then you need to edit the Apache virtual host for your main site and under the ServerAlias list add your reviews subdomain.

Note that in both cases after making the change to your Apache configuration, you would need to run a config test with:

sudo apachectl -t

And only if you get Syntax OK then start Apache.

Hope that this helps! Regards, Bobby