Switching hosting from GoDaddy to AWS

The 4 values you got from Route53 are name servers - they provide the location of where your records are stored (i.e. with Route53). In Route53, you need to have your actual A records. Previously, you (presumably) had one or more A records with GoDaddy which pointed to the elastic IP address of your EC2 instance, now, you need to recreate the same records in Route53 so that a lookup pointed to Route53 (which will be your new nameserver once the change propagates) will return the same record set that you previously had with GoDaddy.

When you access Route53, you get a list of your hosted zones: enter image description here

Select one of them and 'Go to Record Sets':

enter image description here

From there, create a new A record, that points at your elastic IP address.

Update to address your comment:

You have a website, it has some code that renders it. The question is, when I type in example.com into my browser, how do I get to view your code? My browser will do a DNS lookup starting with the root nameservers (.) (which it should already know) - these will provide a list of .com nameservers, where it can lookup the nameservers for example.com. Those nameservers will provide the IP address that can be used to access your code. Your browser then goes to that IP address, and passes a host header to specify which domain it is trying to access (for instance, there could be multiple domains on the same server).

In order to move from GoDaddy to AWS, you can a) just move your code to AWS (if you have a static website, move it to S3 instead of EC2), and point your GoDaddy DNS records at your new host (e.g. your EC2 instance's IP address). In EC2, your instance's IP address will change when the instance reboots, etc. As such it is a dynamic IP address, not well suited for hosting a website. Instead, you need to allocate a static IP address, once that can be assigned to an instance - AWS call this an 'Elastic IP'. This is what you will use for your A record. (The same holds true whether you use GoDaddy's DNS or Route53 - you need an A record that points to the IP address of your server - but there is no requirement to use Route53 just because you are using AWS to host your site - there are some exceptions - e.g. using an elastic load balancer).

enter image description here


Since you were hosting both your domain and website with Godaddy, you probably didn't have to deal with the DNS, they did it automatically for you.

Now that you have Route 53, you need to create a zone for your domain, create all the records such as A record and the MX records for your email to point to the elastic ip of your EC2 instance.

In conclusion, you have to create an A record like this:

yourdomain.com  IN  A   50.115.165.28
www.yourdomain.com  IN  A   50.115.165.28

For MX records (Mail exchange)

yourdomain.com  IN  MX  preference: 5 exchange: mailservergoeshere.com

You can set ppriority to 0 if you only have one server. Lowest priority comes first.


Both domain name and hosting provider is same in your case,You need to go to the Godaddy account and then go to the DNS manager nad have to add A record for new hosting provider ip address that is AWS hosting and also change the DNS to point to AWS hosting provider.

To change namerserver at Godaady:

1.Log in to your Account Manager.

2.Next to Domains, click Launch.

3Select the domain name(s) you want to modify.

4.From the Nameservers menu, select Set Nameservers.

5.Under Setup type, select Custom.

6.Select Add Nameservers.

7.Enter the two nameservers your hosting provider gave you.

You find @ ip address entry for the your domain,change that entry to aws public ip address. It will take to propagate the dns globally.