Custom domains
Links & routing
Put your links on a subdomain of your own, like go.yourbrand.com, with the certificate issued before you move the DNS, and what changes for your apps.
Your links can live on a subdomain of your own: https://go.yourbrand.com/sale instead of https://yourname.dectog.com/sale. One custom domain per account. Links on your DecTog subdomain keep working either way, so links already shared never break.
The deployment has to offer it: it needs Cloudflare for SaaS and three settings, described in Self-hosting: custom domains. Until then the Settings card says it is not set up.
Add the domain
Section titled “Add the domain”- In Settings > Custom domain, enter the subdomain, for example
go.yourbrand.com, and select Add. A subdomain, not the bareyourbrand.com: a CNAME record cannot sit on a domain apex at most DNS hosts. - The card lists three DNS records. Add them at your DNS host:
| Type | Name | Value | Why |
|---|---|---|---|
| TXT | _cf-custom-hostname.go.yourbrand.com |
a token | Proves the domain is yours |
| TXT | _acme-challenge.go.yourbrand.com |
a token | Lets Cloudflare issue the certificate |
| CNAME | go.yourbrand.com |
the deployment’s target, domains.dectog.com on hosted DecTog |
Sends the domain to DecTog. Add it last. |
- Wait. The card checks every minute while it is open, and the server once an hour otherwise; Check now asks at once.
The two TXT records let the certificate issue while go.yourbrand.com still points wherever it does today. That is what makes moving a live link domain over (from Branch or Firebase Dynamic Links, say) free of downtime: the CNAME changes only once DecTog can already answer on it with HTTPS. If the subdomain is new and nothing uses it yet, you can add the CNAME straight away and skip the TXT records; Cloudflare then validates over HTTP once the CNAME points at it.
The states
Section titled “The states”| State | Meaning | What to do |
|---|---|---|
| Waiting for DNS | Cloudflare has not seen the TXT records (or the CNAME) yet. Its message is shown under the records. | Add the records; DNS changes can take a while to spread. |
| Issuing certificate | Ownership is proven; the certificate is being issued. | Wait a few minutes. |
| Ready: point the CNAME | The hostname and its certificate are live. | Add (or change) the CNAME. |
| Active | The CNAME points at DecTog: the server saw it in DNS, or a request arrived while DNS sends the domain to Cloudflare. Every new link URL uses the domain. It stays active while Cloudflare renews its certificate or redeploys the hostname. | Add it to your apps (below). |
| No longer points here | It was active, and Cloudflare reports the CNAME moved away. Links are built on your DecTog subdomain again. | Restore the CNAME; otherwise the domain is removed 7 days later. |
| Failed | Cloudflare refused the hostname or gave up validating it. | Remove it and add it again, or check the records. |
A DNS host that hides the CNAME behind its own proxy (a proxied record on a domain that is itself on Cloudflare) never shows it to a DNS lookup; such a domain turns active with the first tap that reaches it, once its addresses are Cloudflare’s. A request alone never activates a domain: before you move DNS, anyone can ask Cloudflare for the certificate-ready host, so DecTog also checks that public DNS really sends it there.
What changes once it is active
Section titled “What changes once it is active”- Every link URL the API, the dashboard, the SDK, webhooks and install verdicts return is
https://go.yourbrand.com/<slug>. So are the QR page’s code, the preview’sog:urland the link the iOS tap-to-store page copies to the pasteboard, which keeps deterministic iOS attribution working on the new domain. - The domain serves your links,
/.well-known/apple-app-site-associationand/.well-known/assetlinks.json, and its root redirects to your app’s Fallback URL when one is set. It never serves another account’s link, not even through/r/<username>/<slug>. - Your DecTog subdomain keeps serving every link.
Add it to your apps
Section titled “Add it to your apps”Universal Links and App Links are per host, so the apps need the new host next to the old one. The Apps page’s “Copy for AI” prompts list both once the domain is active.
- iOS: add
applinks:go.yourbrand.comto the Associated Domains, next toapplinks:yourname.dectog.com, in every entitlements file. - Android: add
<data android:host="go.yourbrand.com"/>to theautoVerifyintent filter that has your DecTog host. - SDK: list the domain in
DectogConfig(linkDomains: ['go.yourbrand.com']). The SDK also learns the active domain from the server, but only after its first answer; listing it covers a link that opens the app on its very first start.
Ship a build with these before you share links on the new domain: until then, taps on it open the browser and route through the stores like any other tap.
Remove it
Section titled “Remove it”Remove asks first. A domain that was serving is suspended rather than deleted: new links are built on your DecTog subdomain at once, taps on the domain keep working for 7 days, and Restore undoes the removal in that time. After 7 days the hostname is deleted. A domain that never went live is deleted at once.
Adding another domain during those 7 days replaces the removed one only once Cloudflare has accepted the new hostname: if it refuses (the hostname is taken, or Cloudflare does not answer), the removed domain keeps serving and Restore still works. Adding the removed domain again restores it.