When hosting your app on Vercel and pointing your custom domain to it, you need to configure your domain’s DNS records at your domain registrar (where you bought your domain) based on whether you are using an apex domain (e.g., example.com) or a subdomain (e.g., www.example.com).
Here are the key steps:
- Add your domain to your Vercel project:
- Configure DNS for your domain at your domain registrar:
- Apex domain (example.com):
You must create an A record pointing to the Vercel IP address (e.g.,76.76.21.21
, as shown in tutorials; verify the exact IP in your Vercel dashboard). Use@
to represent the apex domain in your DNS panel. - Subdomain (e.g., www.example.com or app.example.com):
Create a CNAME record where the name is the subdomain (e.g.,www
) and the value is the unique Vercel domain assigned to your project (e.g.,cname.vercel-dns.com
or a project-specific CNAME shown in Vercel).
- Apex domain (example.com):
- Optional: Use Vercel’s nameservers if you want Vercel to manage all DNS records (especially for wildcard domains like
*.example.com
). You need to change your domain’s nameservers to the ones provided by Vercel, and manually add any custom DNS records inside Vercel’s DNS management interface. - Verify domain ownership:
Sometimes Vercel requires you to add a TXT record in your DNS for ownership verification, especially if the domain is used in another Vercel account. - Wait for DNS propagation:
After adding or changing DNS records, it can take several minutes to hours (up to 48 hours) for changes to propagate globally.
Example summary:
Domain Type | DNS Record Type | Record Name | Record Value |
---|---|---|---|
Apex domain | A record | @ (or blank) | Vercel IP address (e.g., 76.76.21.21) |
Subdomain | CNAME record | www (or your subdomain) | Vercel CNAME target (e.g., cname.vercel-dns.com) |
Wildcard domain | Nameservers method | Change nameservers to Vercel’s provided NS addresses | N/A |
Once DNS is correctly configured and verified, your domain will point to your Vercel-hosted app.
This setup process is explained and supported in detail in Vercel’s official docs and user guides, as well as community tutorials.
Using Vercel’s nameservers or DNS management alone is insufficient for proper email hosting because Vercel does not provide SMTP/email hosting or highly optimized mail DNS services out-of-the-box. This means:
- You must manually add and maintain all necessary MX, SPF, DKIM, and other email-related DNS records in Vercel’s DNS UI if you delegate DNS management there. Otherwise, your mail will break.
- Using Vercel as a full DNS host requires re-adding these DNS records from your mail provider (Google Workspace, OVH, ImprovMX, etc.) to Vercel’s DNS to ensure mail works properly.
- Vercel also doesn’t offer FTP or traditional file hosting, so any workflows relying on FTP or server-managed mailservers won’t work with Vercel’s platform.
To maintain reliable email functionality when pointing your domain to Vercel hosting:
Approach | Pros | Cons |
---|---|---|
Keep DNS at your registrar | Full control over mail-specific DNS | Must keep A/CNAME for Vercel, MX/SPF/etc. for mail separately |
Use Vercel nameservers | Convenience of unified DNS management | You must manually migrate and maintain mail DNS records at Vercel |
Use third-party DNS with Vercel | Centralized DNS optimized for mail | Can require careful coordination to avoid conflicts |
Recommendations for email alongside Vercel hosting:
- If you change nameservers to Vercel (Option 3), be sure to add the MX records and all mail-related DNS records for your email provider manually in Vercel’s DNS settings to avoid mail delivery failures. For example, MX records for OVH or Google Workspace must be added with correct priority and targets.
- If you want simpler mail DNS management, keep your domain’s DNS at your original registrar or a provider optimized for email, and only add Vercel’s A or CNAME records for your app there. This way, mail records remain untouched and optimized outside Vercel.
- For SPF records, DKIM, and DMARC, add or migrate these TXT records into your DNS provider (whether that’s Vercel or elsewhere) to prevent spam and relay errors.
- Understand that Vercel’s IP address (76.76.21.21) is for web hosting only; your A record for mail should never point to Vercel but to your mail server’s IP or MX targets.
In summary, Vercel is designed as a frontend hosting and deployment platform, not a mail host or full DNS provider specialized in mail. If you choose to delegate DNS to Vercel, you must manually configure all mail DNS entries yourself to keep email functional. Otherwise, managing mail DNS records separately or at your registrar is safer and simpler.
Regarding FTP: Vercel does not support FTP or direct file system access. Deployment is through git or CLI tools only.
Therefore, Option 3 (using just Vercel for DNS and hoping mail works without extra setup) is not advisable if your domain requires email services.
Leave a Reply