Redirect your custom domain to heroku app

Others

Home » Blog » Others » Redirect your custom domain to heroku app

You might have developed a fully functional website and ready for the production so that you can show it to the world. By default heroku gives a default domain like yourdomain.herokuapp.com . Now you wanted to replace that domain with other domain name you wanted like yourdomain.com. It is quite simple and straightforward. I am using namesilo as a domain provider but it does not matter since all the domain providers are same.

First go to settings of the heroku application

Click on add domain button. For this option a mastercard should be linked (don’t worry its absolutely free). Once the button is clicked it will going to provide you a input field.

Make sure you provide the www domain as well

Enter your domain name and save. It will then provide its custom DNS Target . Copy any one of the DNS target and open your domain provider. For this one I am using namesilo domain provider. In your domain provider go to the DNS  section and create a new CNAME record. In the hostname enter ‘www’ and in the target hostname ‘nepmarts.com.herokudns.com’ which I copied from the heroku.

Once saved it will going to take 24-48 hours for DNS propagation and it will redirect your domain to your heroku domain.

About Author

nyasin585

×