Skip to content

Instantly share code, notes, and snippets.

@kuyseng
Forked from mikestone14/gist:11198630
Created February 8, 2017 02:29
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save kuyseng/e7fed1d031cfbd3cec95d083bcc2aa87 to your computer and use it in GitHub Desktop.
Getting a GoDaddy domain to point to a Heroku app.

Pointing a GoDaddy domain to a Heroku app

https://devcenter.heroku.com/articles/custom-domains http://thenomadicfreelancer.blogspot.com/2012/08/pointing-godaddy-domain-to-your-heroku.html

1) Custom Subdomains

For each custom subdomain use domains:add in the Terminal.

heroku domains:add www.example.com

2) Subdomain DNS

Go to the domain's DNS manager and configure it with a CNAME record pointing the subdomain to your herokuapp.com hostname.

Record Name Target
CNAME www example.herokuapp.com

To check that this worked correctly run host www.example.com

3) URL Forwarding

This will work to have www.example.com forward to www.example.herokuapp.com, but it won't work if a user types example.com into the browser.

To get this to work, go to the GoDaddy domain information and set forwarding to www.example.com.

Done!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment