Skip to content
Domain SDK
Esc
↑↓navigate↵open⌘Jpreview
On this page

Handle apex domains and subdomains

Respect adapter capabilities without guessing public-suffix boundaries.

Domain SDK validates full hostnames but does not guess registrable apex domains with a two-label rule. Use domains.capabilities.apexDomains for provider support.

Railway apex instructions use ALIAS/ANAME or CNAME flattening. Vercel supports apex configuration. Cloudflare for SaaS exposes CNAME routing and reports apex support unavailable. Render accepts wildcard domains; other current adapters reject them.

For tenant hostnames under a domain you own, use createSubdomainClient to constrain direct-child labels and choose wildcard or individual provisioning.

For the DNS side, including why the apex can’t hold a CNAME and which record each platform asks for, see Apex domains: A records, ALIAS, and CNAME flattening on the blog.

Read next: Provider overview.

Last updated on