Hellooo people,
Do you want to add a domain to your Vercel project but aren’t sure how? Don’t worry, I got your back. Here is a step-by-step tutorial on how to connect your Google domain to your project. Let’s get this party started!
Step 1 : Vercel Account and Project Setup
I hope you already have a Vercel account and project set up. If you haven’t already, go to the Vercel website and create an account. Signing up is simple and easy, and you may use your GitHub, GitLab, or Bitbucket account. Once logged in, you’ll be able to create a new project using your linked Git Repository account.
Step 2: Add a Custom Domain
Now, go to the Settings page of the newly created project and select Domains. This is where you will enter your own domain.
Enter the domain name and press the Add button. If you don’t have a domain name yet, you can purchase one from the Google Domains.
Step 4: Verify Your Domain
You’ll be brought to a DNS settings section after selecting the Add button.
This is where you need to verify your domain. You’ll need this page for later, so keep it open.
Step 5: Log in to Your Google Domains Console
The next step is to sign in to your Google domain provider account. Choose the domain you want to add from the My Domains list. Proceed to the DNS section.
Step 6: Add the DNS Records
In this step, you must add the DNS records supplied by Vercel. You must generate an A record as well as a CNAME record. These records instruct Google on how to locate your website or online application.
- To create an A record, leave the Name box blank, select ‘A’ as Type, and provide the IP address of your Vercel project in the Data column.
- To create a CNAME record, enter ‘www’ in the Name column, ‘CNAME’ as the Type, and your Vercel project’s URL in the Data field.
Step 7: Verify the DNS Configuration
After adding the DNS records, you must wait for them to propagate. This process can take up to 24 hours. Vercel will try to check the configuration automatically once in a while. You can also trigger this check using the Refresh button. Once its ready, Vercel will validate the DNS settings, and if everything is in order, your Google domain will be linked to your Vercel project.
That's it!
You have successfully linked your Google domain to your Vercel project. I hope you found this guide useful and simple to follow. If I missed anything or if any of the steps feels incomplete, please let me know in the comments.
Cheers and happy coding!