← All guides

Replit Custom Domain Not Working? Fix Verifying, Failed and SSL Errors

Replit

Your app runs fine at its replit.app address, but your own domain won’t cooperate. The Domains tool sits on Verifying, flips to Failed, the browser shows a certificate warning, or the domain opens something other than your app. Each of those has its own cause. Apart from an unpublished or outdated app, the fix for each one is in your DNS settings.

Below: the records Replit looks for, a table that maps each symptom to its cause, and the order to work through the fixes. If the app itself is broken on replit.app too, start with Replit app not working instead. Tool page: /fix/replit.

Symptom to cause: start here

What you seeLikely causeGo to
Stuck on VerifyingRecords missing, mistyped or not visible yet; an extra A or an AAAA record on the same nameSteps 1 to 3
Status says FailedReplit’s checking window (about 6 hours) closed before it saw your recordsFailed: remove and add once
Root domain works, www doesn’t (or the reverse)Only one hostname was connected; www is its own entryRoot vs www
Certificate or “not secure” warning on a new domainCloudflare proxy on, conflicting records, or a CAA record that blocks Let’s EncryptSSL errors
Certificate warning on a domain that used to workThe replit-verify TXT record was deleted or edited, so renewal failedLeave the TXT record in place
Your old website, a parking page or another host’s errorAn old A record from a previous host still answers, or DNS hasn’t caught upStep 2
An older version of your appYou changed the app but didn’t publish againFAQ
Nothing loads, and the Domains tool says the project isn’t publishedThe app hasn’t been published yetCheck this first

Before you touch DNS

Does the replit.app URL work? Replit’s own walkthrough says to confirm the public replit.app address loads and behaves before you change any DNS (Replit: add a custom domain). If it doesn’t, the domain isn’t your problem yet.

Is the app published? You can connect a domain to a project before it’s published, but Replit won’t serve anything on it until you publish. Until then, the Domains tool flags the project as not yet published (Replit: custom domains).

Where is the domain managed? Open Tools, then Domains under Replit Cloud. A domain you bought through Replit points at your project on its own, with no records to add. If one of those won’t verify, Replit’s docs send you to Replit Support. The rest of this guide is about domains registered somewhere else.

Did guided setup run? For a domain you already own, Replit offers a guided flow that hands off to a service called Entri, which logs into your DNS host with your permission and creates the records itself. When your provider isn’t supported, the flow falls back to listing the records for you to add by hand (Replit: custom domains). Either way, the checks below apply, because the result is the same two records.

What Replit needs from your DNS

For each hostname you connect, Replit gives you two records:

TypeHost (name)Value
A@ for the root domain, or the label (www, app) for a subdomainThe IPv4 address shown in the Domains tool
TXTSame host as the A recordreplit-verify=... exactly as shown

A few rules from Replit’s docs that the setup screen doesn’t spell out:

  • A only. Replit supports A records, so an AAAA (IPv6) record on the same hostname causes trouble. Replit’s docs describe no CNAME-based way to point the domain at your app.
  • One A record per name. Two A records pointing to different servers on one hostname is listed as a setup problem.
  • If your provider rejects @, type your registered domain name in the host field instead.
  • A CNAME warning is about email. If the Publishing tool asks for CNAME records, Replit says those are for sending email from your domain. They don’t affect verification, SSL or sign-in (Replit: custom domains).

Step 1: add both records exactly as shown

Do both halves in one sitting: the domain in Replit, the records at your DNS host. Replit polls for your records every minute or two, but only for roughly 6 hours after you add the domain (Replit: custom domains). If your provider is slow to publish changes, Replit suggests adding the records first and the domain second.

Add the A and the TXT together. Replit can’t issue the certificate until the A record points at it.

Copy and paste the values rather than retyping them. Replit lists three mistakes it sees when records “look right” but don’t match (Replit: add a custom domain):

  • A trailing dot pasted into a value or host field.
  • An extra subdomain. If your provider appends the domain to whatever you type in the host field, a host of www.example.com becomes www.example.com.example.com. Type only www.
  • A stale record left over from an earlier attempt or an earlier host.

Step 2: remove conflicting records

On the hostname you’re connecting, keep exactly one A record (Replit’s) and the replit-verify TXT. Delete:

  • Any other A record on that name, such as one from a previous host or your registrar’s parking page.
  • Any AAAA record on that name. Replit’s troubleshooting section says these can block SSL.
  • A CNAME on that name, if your provider set one by default (for example on www). DNS doesn’t allow a name with a CNAME to carry any other records (Let’s Encrypt: CAA notes this rule), so it would stop your A and TXT from working.

Leave unrelated records alone: MX and email TXT records (SPF, DKIM) on the root don’t interfere.

Step 3: if you use Cloudflare, set the record to DNS only

In Cloudflare’s DNS table, click the orange cloud next to the A record so it turns grey (DNS only). Replit’s docs say the proxy interferes with SSL provisioning and stops Replit from renewing the certificate automatically (Replit: custom domains).

Two Cloudflare behaviours make this easy to miss:

  • A proxied record answers DNS lookups with Cloudflare’s own IP addresses instead of the one you typed. A lookup that shows an address other than Replit’s is a sign the proxy is still on.
  • If one A record on a name is proxied, Cloudflare treats every A record on that name as proxied (Cloudflare: proxy status).

TXT records are never proxied, so there’s nothing to change on the verification record.

Root vs www and other subdomains

Connecting example.com does nothing for www.example.com. Replit treats www like any other subdomain: give it its own row in the Domains tool, and it receives its own A record and its own replit-verify TXT, both on host www (Replit: custom domains).

The same goes for app.example.com, beta.example.com and so on. Each one is its own entry with its own pair of records. A TXT value from the root entry won’t verify a subdomain.

If you’d rather send every visitor to one address, Replit’s docs mention setting up a redirect at your registrar between the root and www.

Wildcards (*.example.com) aren’t supported. Each hostname gets its own certificate from Let’s Encrypt, and Let’s Encrypt caps the number of certificates it issues per domain and per hostname. If you plan to add dozens of subdomains, Replit’s page explains the limits and how to add them in batches (Replit: custom domains).

Wait time and how to check propagation

Replit’s docs allow up to 48 hours for new records to propagate, though it can be minutes. Meanwhile your app stays reachable on its replit.app address. Don’t judge by your browser alone, since your computer and your network can cache old answers. Ask public resolvers directly instead.

On macOS or Linux, in a terminal:

# A record: should return only the IP shown in Replit
dig +short A example.com @1.1.1.1
dig +short A example.com @8.8.8.8

# Should return nothing
dig +short AAAA example.com @1.1.1.1

# Should include "replit-verify=..."
dig +short TXT example.com @1.1.1.1

# Repeat for www or any subdomain you connected
dig +short A www.example.com @1.1.1.1
dig +short TXT www.example.com @1.1.1.1

# Any CAA records? (see the SSL section)
dig +short CAA example.com @1.1.1.1

On Windows, nslookup does the same job:

nslookup -type=A example.com 1.1.1.1
nslookup -type=TXT example.com 8.8.8.8

How to read the answers:

Lookup resultMeaning
The Replit IP, and only thatA record is right
Two or more IPsAn extra A record still exists
An IP you don’t recogniseOld host’s record, or Cloudflare proxy still on
Any AAAA answerDelete the AAAA record
No replit-verify= in the TXT outputTXT missing, on the wrong host, or not published yet
Different answers from 1.1.1.1 and 8.8.8.8Still propagating; wait and check again

If both resolvers show the right values, waiting is the fix. If they show anything else, fix the records first; the clock doesn’t matter until the answers are right.

Failed or stuck: remove the domain and add it once

When roughly 6 hours pass without the records showing up, Replit stops checking and marks the domain Failed. Records that appear later are ignored until you start over (Replit: custom domains).

To retry:

  1. Confirm with the lookups above that the A and TXT answers are correct from public resolvers.
  2. In the Domains tool, remove the domain.
  3. Add it again. Check the TXT value Replit shows now, and update your DNS if it differs from the one you added before.
  4. Wait for Verified, then load the domain over https://.

Do this once per domain, not repeatedly. Every remove-and-add requests a fresh certificate. Let’s Encrypt allows only 5 new certificates for the same exact set of identifiers every 7 days; Replit issues one certificate per hostname, so that’s five new certificates per hostname in that window (Replit: custom domains; Let’s Encrypt: rate limits). Retrying again and again only stretches a lockout out longer. Don’t remove and re-add a domain that already works, either.

If several subdomains fail together while the records check out, a certificate limit may be the reason. Replit suggests searching your domain on crt.sh to count recent certificates, or contacting support with the domain and the affected subdomains.

SSL errors after it connects

Replit issues the certificate itself once the domain verifies; you don’t upload one. If the browser warns about the certificate:

  • Proxy still on. Recheck Step 3. Replit can’t provision or renew its certificate while the proxy sits in front.
  • AAAA record present. Replit supports only A records, and its troubleshooting steps say an AAAA record on the same hostname can block SSL. Remove it.
  • CAA record that excludes Let’s Encrypt. CAA records list which certificate authorities may issue for your domain. Replit’s certificates come from Let’s Encrypt, so if your domain has CAA records and none of them names letsencrypt.org, issuance can fail. Add CAA 0 issue "letsencrypt.org" alongside your existing entries; multiple issue records add up rather than replace each other (Let’s Encrypt: CAA). Replit’s own docs don’t mention CAA, so treat this as a check, not a confirmed Replit requirement.
  • Rate limit after repeated retries. See the section above.

After fixing, Replit’s troubleshooting steps say to disconnect and reconnect the domain one time to force a new certificate, then wait several minutes before reloading.

Leave the TXT record in place

The replit-verify TXT record isn’t a one-off ownership check. Replit uses DNS validation each time it renews your certificate, and that depends on the record still being there (Replit: custom domains).

If someone tidies up DNS and deletes it, nothing breaks right away. The next renewal fails quietly, the current certificate runs out, and visitors start seeing a security warning. Replit’s docs note the telltale pattern: certificate warnings on your older domains, while recently added ones still load cleanly.

To recover:

  1. In the Domains tool, look up the replit-verify=... value Replit shows for that domain.
  2. Recreate the TXT record at your DNS host, using that exact host and value.
  3. Delete the domain from the Domains tool and re-add it a single time, which requests a new certificate.
  4. Wait for Verified again.

The same applies to every subdomain’s own TXT record. Keep all of them.

Replit says sign-in with Replit Auth works on a verified custom domain without extra setup (Replit: custom domains). Third-party services are different. Replit’s walkthrough calls out Stripe redirect URLs that still point at the replit.app address (Replit: add a custom domain). The same check applies to Google OAuth clients, webhook URLs and any hard-coded links: add or switch them to the new domain.

If your app uses Supabase for login, its Site URL and redirect list also need the new domain. The Supabase auth redirect guide walks through both.

FAQ

Why does Replit say my domain failed to verify?

Failed means Replit’s checking window of about 6 hours ended before it found matching records. Fix the records, confirm them with dig or nslookup against a public resolver, then remove and re-add the domain once. If it’s still on Verifying rather than Failed, Replit is still checking; compare your records against the Domains tool and remove any extra A or AAAA records.

Do I need the www version too?

Only if you want www.example.com to work. Replit doesn’t add it automatically. Connect it as its own entry, with its own A and TXT records on host www.

Can I use a subdomain?

Any subdomain works. Enter the full name (for example app.example.com) into the Domains tool, then create the A and TXT pair Replit shows for it, both on host app. Each subdomain is verified and certified separately, and wildcard domains aren’t supported.

Why does my domain show the old app or a Replit page?

Publishing saves a snapshot of your project, and the domain serves that snapshot. Changes you make in the editor show up only after you publish again (Replit: deployments). If you see a different website entirely, an old A record is still in place. And if the domain is still attached to a different project in your account, the Domains tool flags that and lets you move it over.

Does it work for a deployment that isn’t public?

Replit’s custom domain docs don’t address this directly. What the access docs do say: with the Workspace only or Invite only options, anyone without access hits a Replit login screen first, and Password protected asks for a shared password instead. So if your domain shows a Replit sign-in or password screen, check the Sharing setting in the Publishing tool. Changing it means unpublishing, choosing a new option and publishing again (Replit: who can access your app).

Can Cloudflare stay proxied if I really want its features?

Replit’s docs say to use DNS only, because the proxy blocks automatic certificate renewal. Keeping the proxy on is outside what Replit supports for custom domains.

I’m thinking about hosting somewhere else instead. What moves with the domain?

The domain is yours and can point anywhere, but the database, secrets and backend don’t come along by themselves. See Moving an app off Replit or Base44. If your app was built on Lovable rather than Replit, the DNS rules differ; see Lovable custom domain not working.

Comments

Add a comment

Generated for you. Click to type your own.

Required. Never shown on the page. Privacy policy.

Basic markdown: **bold**, *italic*, `code`, lists, quotes, and fenced code blocks. HTML shows as plain text.

Your draft stays on this device until you post.