This tutorial shows how to link a custom domain to your published Replit project so it's accessible at your own URL.
Notes:
- You need a published Replit project before connecting a domain. If you haven't published yet, see How to Deploy a Flask App on Replit or any relevant deployment tutorial first.
- You need an existing domain from a registrar like Namecheap or GoDaddy. Alternatively, you can purchase a domain directly through Replit to skip the DNS setup.
- DNS propagation can take up to 48 hours after updating your records, though it often completes within 20 minutes.
- If you're using Cloudflare, turn off the DNS proxy (orange cloud icon) to prevent SSL conflicts - Replit manages its own SSL.
- Sign in at replit.com and open your published project from the dashboard.
- In your workspace, click New Tab and select Publishing.
- Navigate to Domain and click Link a domain.
- Enter your custom domain - for example, example.com - and click Continue. Replit generates an A record and a TXT record for your domain.
- Log in to your domain registrar and open DNS management. Add the A record and TXT record provided by Replit.
- Return to Replit and click Link. Once DNS propagates, your project will be live at your custom domain.
.gif)
