Connect a custom domain
Point the domains you own at your published site, and understand why a domain sits on Pending instead of failing.
On this page
A custom domain puts your site on an address you own. A site can have up to 10 custom domains, and every one you connect serves the same site. Your free .modulify.website address keeps working alongside them, so nothing breaks while you set this up.
Before you begin
You need three things: a domain you already own, the ability to add DNS records for it, and a paid plan. A domain bought on the workspace's Domains page counts, and while it uses Modulify's nameservers Modulify adds its records for you, see Records Modulify manages. No domain yet? Buy one from the panel itself, see Buy a domain for a site. On a free workspace the row carries a Paid badge, the Custom domain field is disabled, and hovering Connect shows A paid plan is required to add a custom domain. See Plans.
Adding or removing a domain needs the Manage domains permission, which the workspace owner always has and which a custom role can be given. Without it the Connect button is disabled with the tooltip You do not have permission to do this. See Members and roles.
You can connect a domain before your first publish, but until the site is published it only shows a Modulify page that reads This site isn't published. The field says as much: Connect a custom branded domain. Every domain you add serves the same site and takes effect immediately if an initial publish exists.
Open the Domain panel
Open the project, click More in the tab strip, then Domain. The address is /dashboard/projects/<project>/domain, and the panel is headed Domain, Connect custom domains to your published site.
On a Free workspace you own, a published site also shows a Connect domain button in the strip above the preview frame. That one opens the plan and credits modal rather than this panel, because the field here stays disabled until the workspace is on a paid plan.
From top to bottom the panel holds your free subdomain, the Custom domain field with a Buy a domain button under it, then one card for each domain on the site in the order you added them, with your project's details underneath. The free subdomain is covered in Your free web address.
Enter the domain
Type the hostname into the Custom domain field. The placeholder shows the two shapes it accepts, modulify.ai or blog.modulify.ai. Press Enter or click Connect. The field stays at the top of the panel however many domains the site has, so adding a second domain works exactly like the first.
Enter the bare hostname, or paste a full address and the field keeps only the hostname: pasting https://www.example.com/pricing leaves www.example.com, without the https://, the path, a query, a port or a login. The field validates as you type and refuses four things.
| Message | Cause |
|---|---|
| Domain should not include http:// or https://! | You typed a full URL rather than pasting it |
| Domain should not include a path! | The value contains a / you typed |
| Domain must be between 4 and 253 characters! | Too short or too long to be a hostname |
| Domain must be a valid domain! | Not a well formed hostname |
Some endings are worth avoiding. Type a domain on an ending that many networks filter and a note appears under the field: Some networks and company firewalls refuse to resolve .lol domains, so a few visitors will see a server not found error. A .com or .org reaches more people. It is advice rather than an error, and Connect still works. Troubleshoot a domain explains what those networks actually block.
A leading www. is not an error. Modulify strips it and connects the root instead, then attaches the www hostname as the companion, so www.example.com and example.com reach the same place. See www and apex domains.
Buy a domain for a site
Under the Custom domain field, a box headed No domain yet? reads Buy one and Modulify connects it to this site., or Buy one for this workspace. when the site cannot take another domain, with a Buy a domain button. The button opens Buy a domain, Buy a name and Modulify connects it to this site., with the same search and extension prices as the Domains page, see Search for a name. Click Buy on a result to register it, see Register it.
Once the domain is paid for and its registration is confirmed, Modulify connects it to the site by itself, as if you had clicked Connect, and its card joins the panel. That holds when the confirmation comes later too, for example after a payment the registrar takes longer to confirm, so you do not need to keep the page open or click Connect. The workspace owns the domain, so while it uses Modulify's nameservers there are no records for you to add. When the payment needs a Stripe checkout page, a Do you want to continue? prompt comes first and Go to checkout opens the page in a new tab. Pay there and that tab comes back to the Domain panel, while the panel you started from picks up the domain by itself once it is connected. Cancel the prompt, or go back from the checkout page without paying, and nothing is connected.
Modulify makes that connection as the person who bought the domain, under the same rules as Connect, so the site still needs room for another custom domain by then. When it is refused, the domain is still registered and you can connect it yourself.
When the workspace already owns the name you search, its card reads In this workspace, with a Connect button that connects it straight away. One the site already has reads On this site instead. A domain whose registration is not confirmed yet cannot be connected: its card reads Registering instead of In this workspace, and Connect is disabled with the tooltip Connect it once its registration is confirmed.
The domain is bought for the workspace that owns the site, and buying needs its Manage billing permission, which only its owner holds. For anyone else Buy a domain is disabled with the tooltip You do not have permission to do this. When the site cannot take another domain, because the workspace is on Free, the site already has 10 domains or you do not have the Manage domains permission, the dialog reads Find a name and register it for this workspace. instead, and the domain you buy is not connected for you. Connect on a domain the workspace owns is then disabled, with the same tooltip as the Connect button next to the field.
A domain nobody owns yet
When you click Connect, Modulify first checks whether the domain is registered. When nobody owns it and Modulify sells it, a dialog asks before anything is added. It is headed with the domain, for example example.com is not registered yet, reads Buy it now and Modulify connects it to this site., and shows the price of the first term and what renewing costs.
- Buy example.com opens the Register domain dialog. Once it is paid for and its registration is confirmed, the domain you entered is connected for you, as above. For a subdomain such as
blog.example.com, it buysexample.comand connectsblog.example.com. - Connect anyway connects the domain as you entered it, for example when you are about to register it somewhere else.
- Cancel closes the dialog and leaves the field as it was.
For anyone without the Manage billing permission, Buy example.com is disabled with the tooltip You do not have permission to do this., and Connect anyway still works. A domain that is registered already, or one on an extension Modulify does not sell, connects straight away.
In the mobile app the same question shows as a sheet, reading Domains are bought on the Modulify website, which opens in your browser. Once it is yours, connect it here. Buy example.com opens the workspace's Domains page on the website with the name already searched. The app does not connect it for you after the purchase, so tap Connect again once the domain is yours. Connect anyway and Cancel work as in the editor, and without the Manage billing permission Buy example.com is disabled with You do not have permission to do this. under it.
What happens on Connect
Modulify sets up the site's production server if it does not exist yet and works out the DNS record each hostname needs, for your domain and its www companion. The TLS certificates are issued once those records point at Modulify and the domain is verified. Every domain you add is served by the same deployment, so a second domain changes nothing for the first.
You get a Domain added toast naming what is now waiting, for example example.com and www.example.com are both waiting on DNS. Add the required records at your DNS host, including the TXT record that proves you own example.com, to finish connecting them. A new card headed Your custom domain appears under the field, after the cards already there, with a table of records underneath, each row reading Pending until its record checks out. Among them is the TXT record that proves the domain is yours, see The ownership record. The field empties, ready for the next domain.
If the www hostname of the root you entered already belongs to this site or to another site in this workspace, Modulify adds the root on its own and the toast names only the root: example.com is waiting on DNS. Add the required records at your DNS host, including the TXT record that proves you own it, to finish connecting it. When a site in another workspace has it, Connect asks you to prove you own the domain first, see One site per domain.
When Connect refuses
| Message | Cause |
|---|---|
example.com is already connected to this site! |
The hostname is already on this site, as one of its domains or as the www variant of one |
example.com is connected to Lisbon Pottery. Remove it there first, then connect it here! |
Another site in this workspace has that hostname, here a site named Lisbon Pottery. Remove it from that site first |
example.com is already connected to another site! |
Another site connected that hostname while this one was being added |
A site can have up to 10 custom domains! |
The site already has 10 domains. Remove one first |
You cannot use a Modulify domain as a custom domain! |
The value is on an address Modulify already owns |
example.com is too long for the TXT record that proves you own it, so it cannot be added! |
The domain is longer than 230 characters, so the name of its ownership record would not fit in DNS |
example.com is still being registered, so connect it once its registration is confirmed! |
The workspace bought example.com and the registrar has not confirmed the registration yet. A subdomain of it is refused the same way |
Once the site has 10 domains, the field and Connect are disabled, and hovering Connect shows A site can have up to 10 custom domains.
One site per domain
A hostname belongs to one site at a time across all of Modulify, so Connect first checks where the domain is.
| Where the domain is | What Connect does |
|---|---|
| On no site | Adds it, with the TXT record that proves you own it among its records, see The ownership record |
| On another site in this workspace | Refuses and names that site. Remove the domain there, then connect it here |
| On a site in another workspace | Adds nothing until you prove you own it, then moves it to this site |
For a domain a site in another workspace has, Connect shows its TXT record in A domain waiting on verification instead, and a Verify ownership toast reads example.com is used by another Modulify site. Add the TXT record to prove you own example.com, and verifying it moves it to this site. The check covers the www variant too: when a site in another workspace has www.example.com, connecting example.com asks for the record, and verifying moves both. When example.com is already on your card and verified, Add www moves www.example.com off that site without another record, see www and apex domains. When the domain is verified, the site that had it stops answering on it straight away, and the Domain verified toast ends with example.com was moved here from another site., or names both hostnames when the www variant moved too.
A domain the workspace bought on its Domains page needs no TXT record, because buying it proves it is yours. Connect adds it straight away, and takes it off a site in another workspace that has it.
To move a domain to a different site in the same workspace, remove it from the site that has it, then connect it on the other one. When it was verified on the site you removed it from, it needs no new TXT record as long as you connect it within 30 days. Deleting the site that has a domain frees it too, so another site in the workspace can connect it, and that window then counts from the delete. Restoring the deleted site gives it back its domains, except any that another site connected in the meantime.
The ownership record
A domain serves your site only once you have proved it is yours. Until then its records table has one more row, a TXT record:
| Type | Name | Value |
|---|---|---|
| TXT | _modulify-verification |
modulify-verify= followed by a code for this domain |
Names are shown relative to your domain, so for a subdomain such as blog.example.com the name reads _modulify-verification.blog. For a www hostname, such as a card whose root was removed, the record sits on the root domain: _modulify-verification.example.com covers www.example.com too, so removing the root from a card keeps the record you added working.
The record only counts as a TXT record at exactly that name. A CNAME at that name does not count, even when the name it points to has the right TXT record.
Only someone who runs the domain's DNS can add it, so nobody can put their site on a domain that is yours, even while its records point at Modulify. Until the TXT record checks out, neither the domain nor its www variant reads Connected or answers with your site, even when every other record is in place. The card says so: Add the records below at your DNS host. The TXT record proves the domain is yours, and your site answers on it once every record checks out. It is removed if it stays unverified for 14 days without a check, and opening this tab checks it.
Modulify looks for the record while the Domain panel is open, and every 10 minutes when it is not. Once it is found the row leaves the table, and you can delete the TXT record at your DNS host.
These domains need no TXT record:
- A domain the workspace bought on its Domains page. Buy one that is already on a card waiting for its TXT record, and it is verified at the next check.
- A domain a site in this workspace had verified, connected again within 30 days of removing it from that site or deleting the site.
- A domain that was connected before Modulify asked for the record.
Connect on a domain already on the site while it waits for its TXT record checks it straight away. When the record is in place, or the workspace bought the domain, the toast reads example.com was already on this site, and its ownership is now verified., and otherwise Connect is refused with example.com is already connected to this site!
When the DNS host supports one-click setup, the Connect with banner reads One step at Cloudflare adds the address records below. Add the TXT record yourself, because one-click setup cannot add it., naming your provider. Chat and AI clients that hand you a one-click link give you the TXT record along with it for the same reason.
A domain whose TXT record is still missing 14 days after it was added, or after it was last checked from the Domain panel, chat or an AI client, is removed from the site. While the site's custom domains are paused nothing is removed, and the 14 days start over once they resume. Connect it again whenever you are ready: in the same workspace, within 30 days, it gets the same TXT record as before.
Each domain has its own card
Every domain sits in a card of its own, headed Your custom domain, with the hostname and a Remove button. The description under the heading says where that domain stands.
| Description | When |
|---|---|
Links to your live site and the links in your texts use this domain. |
The domain is connected and it is the primary |
Your site also answers on this domain. |
The domain is connected and another one is the primary |
Add the records below at your DNS host to connect this domain. |
The domain is not connected yet |
Add the records below at your DNS host. The TXT record proves the domain is yours, and your site answers on it once every record checks out. It is removed if it stays unverified for 14 days without a check, and opening this tab checks it. |
The domain still needs its ownership record |
Modulify adds the records that connect this domain for you. |
The domain is not connected yet, and it is one the workspace bought |
Not serving your site while paused. |
The site's custom domains are paused |
For a root domain, the card also holds its WWW variant row, see www and apex domains. When the domain's DNS provider supports one-click setup and a hostname on the card is not connected yet, the card starts with its own Connect with <your provider> button, which reads Connect automatically when the provider does not give its name, see One click setup. When the domain is one the workspace bought on its Domains page, or a subdomain of one, and it uses Modulify's nameservers, the card has nothing to add: it starts with a banner holding Manage DNS instead, and the records sit folded behind a DNS records toggle, because Modulify adds them itself, see The site's Domain tab.
The primary domain
One connected domain is the primary, and its card carries a Primary badge next to Connected. Make primary on any other connected card makes that domain the primary, in the web editor and the mobile app, and a card still waiting for DNS has none. Until you choose one, the primary is the domain under Your custom domain on the first card, in the order you added them, where that domain is connected. After a root was removed, that domain is its www hostname, and it still counts. Only while none of those domains is connected does the primary fall back to the first connected hostname in a card's WWW variant or Root domain row, and that row carries the badge instead.
Modulify shows the primary wherever it shows only one of your domains. That covers the links and examples in your site's texts, Copy published app link and Open published project in the dashboard, the Custom domain row of the publish popover, a template's preview link, the redirect hint on your free subdomain, and the customDomain that webhooks and AI clients read. Every other connected domain still serves the site in full.
When the primary is removed, the primary is worked out again from the domains that remain, by the order you added them. AI clients choose it with set_primary_domain.
The records Modulify shows you
The table has four columns, Type, Name, Value and Status, and one row per record required for that hostname. When your domain's nameservers are Cloudflare, a fifth column, Proxy, reads Off on every row. A name and a value are plain text, and the copy icon next to each one copies it.
Above the table, a line names the zone the record belongs in: Add the following record at the DNS host that manages example.com (not any other domain). DNS changes can take a few minutes to propagate. That is whoever runs the nameservers for the domain today, which is often not the company you bought it from. Each domain can sit with a different DNS host, so read the line on each card. A domain the workspace bought that still uses Modulify's nameservers has nothing to add: its table sits folded behind a DNS records toggle, because Modulify adds the records itself, see Manage DNS for a bought domain.
Names are shown relative to your domain, so your apex reads @ rather than the full hostname.
DNS records explains what each record is for, the Cloudflare Proxy column, and the one click setup button that some DNS providers support.
Every record, then Connected
Modulify marks a hostname Connected when every record in its table resolves to Modulify and the certificate for it has been issued. For a root domain that is one A record. For the www hostname or a subdomain it is one CNAME. While the domain still needs its ownership record, its table has that TXT row too, and neither the domain nor its www variant connects until it checks out.
Once the record points at Modulify, the certificate is usually issued within a minute or two and a Connected badge appears next to that card's heading on its own. Until then the heading carries no badge, so check each row's own Status: a row that stays on Pending or Invalid is the one to look at.
While you wait
The panel checks every domain when you open it, then keeps re-checking each domain that is not fully connected while you have it open, and the Connected badges appear without a refresh. Domains that are already connected are left alone. Modulify also checks every domain that is not connected every 10 minutes, with the panel closed, and every connected domain once a day: a domain whose records no longer point at Modulify loses its Connected badge, and stops being the primary, until they do again. DNS usually propagates in minutes, though some providers take hours. How Modulify re-checks has the timings.
Your free .modulify.website address and your connected domains serve the whole time, so the site is never offline while a new domain is pending.
If a row reads Invalid, a banner under it names the exact problem. Troubleshoot a domain works through every cause in order.
A domain waiting on verification
A domain waits on verification when a site in another workspace has it, see One site per domain. An AI client can also ask to prove ownership of a domain first, see start_domain_verification. While one is waiting, the panel shows Pending verification for example.com under the field, with the TXT record to add, a Verify and connect button and Cancel. Its name is shown relative to your domain like on the cards, _modulify-verification for example.com or _modulify-verification.blog for blog.example.com. Add the record at the DNS host that manages the domain and give it a few minutes to propagate.
When Modulify cannot reach DNS at the moment you click Verify and connect, it is refused with DNS could not be checked right now, so the domain was not verified. Please try again in a minute! and nothing changes.
Verify and connect adds the domain as a new card once the TXT record checks out, and takes it off a site in another workspace that has it, along with its www variant. The Domain verified toast says whether it is connected yet, for example example.com is verified and waiting on DNS. Add the required records at your DNS host to finish connecting it. The card then needs no TXT record of its own, because the domain is already verified, only its A or CNAME record if that is not in place yet.
A site has one pending verification at a time. Clicking Connect again for the same domain keeps the same TXT record, and once the other site has let the domain go, Connect adds it as a card with that same record. Another domain that needs proof takes the place of the waiting one. A waiting verification does not stop you connecting other domains in the meantime.
On a free workspace Verify and connect is disabled, and hovering it shows A paid plan is required to add a custom domain. Once the site has 10 domains it is disabled too, with A site can have up to 10 custom domains. Cancel still works.
When the waiting domain ends up on the site another way, through Connect once no other site has it or with Add www or Add root on a card, the pending verification is cleared. If the domain is already on the site when you click Verify and connect, it is refused with example.com is already connected to this site! and the pending verification is cleared too. If another site in this workspace has it by then, it is refused with example.com is connected to Lisbon Pottery. Remove it there first, then verify it again! and stays waiting.
Replacing or removing a domain
Domains sit side by side, so moving to a new domain needs no gap. Connect the new one, wait for it to read Connected, then remove the old one. If the old one was the primary, the primary is worked out again from the domains that remain. When it has a connected www variant, though, removing it leaves that www hostname on the card as its own domain, still connected, so it stays the primary. Choose Make primary on the new domain's card when it should become the primary instead.
Remove on a card asks first. The dialog is titled Remove example.com? and the confirm button reads Remove domain. The description depends on what else is there.
| Description | When |
|---|---|
Your site will stop working at example.com. www.example.com stays connected, remove it separately if you want that one gone too. |
The domain has a connected www variant |
Your site will stop working at example.com. www.example.com stays on the site, remove it separately if you want that one gone too. |
The domain has a www variant that is not connected yet |
Your site will stop working at example.com. Your other domains keep working. |
The site has other domains |
Your site will stop working at this domain. Anyone visiting it will see an error until you connect a new domain. |
It is the site's only domain |
The Domain removed toast then reads Your site is no longer reachable at example.com. Your other domains keep working., or ends with Connect another domain whenever you are ready. when it was the last one. Removing a domain never touches the other domains. When the domain has a www variant, the toast reads example.com was removed. www.example.com is still connected, remove it separately if you want that one gone too., or says the variant stays on the site when it is not connected yet, and its card stays with the www hostname in its place, see Removing one of them.
When your plan ends
A custom domain needs a paid plan to serve your site, not only to be added. When the workspace's plan ends and the workspace is on Free, the site's custom domains are paused. A payment that failed and is still being retried pauses nothing, and neither does a cancellation that is only scheduled, so the domains keep serving until the day the plan actually ends. A site moved into a workspace on Free has its custom domains paused the same way.
While they are paused:
- Every domain stays on its card, but none of them shows the site, and a visitor gets an error instead. Your free
.modulify.websiteaddress keeps working. - The panel shows Custom domains are paused above the cards,
They stay offline until this workspace is on a paid plan again., with a See plans button. In the mobile app, See plans opens the Plans page on the Modulify website in your browser. - The cards lose their Connected and Primary badges and their records, and every domain on them reads
Not serving your site while paused. - Links to your live site use your free address instead, and the Custom domain row of the publish popover offers Add a custom domain.
- Remove still works. Adding a domain again later needs a paid plan.
Nothing is deleted, and no DNS record has to change. Once the workspace is on a paid plan again, the domains come back on their own, usually within a minute or two.
From chat
You can also ask chat to connect a domain, in plain words such as connect example.com to my site. It adds the domain and its www variant, then reads you the exact records to add at your DNS provider, or gives you a one-click setup link when your provider supports it. Once you have added them, ask it to check again. It runs the same checks as the Connect button: a paid plan and the Manage domains permission. Chat can remove a domain or its www variant too, after you confirm. A new domain comes with the TXT record that proves it is yours, see The ownership record, and chat reads it to you with the others, also when it gives you a one-click link, because that link cannot add it. When a site in another workspace has the domain, chat gives you that TXT record first, and once you have added it, chat verifies the domain after you confirm, which moves it off the other site. Adding the records at your DNS provider is always yours to do. For a domain the workspace bought on its Domains page that uses Modulify's nameservers, chat tells you there is nothing to add, because Modulify adds the records itself.
Chat can also look up domains you could buy, with what they cost, and the domains the workspace already bought, including their DNS records. Chat buys one only through a card you approve, see Buy a domain from chat, and you can always use the Buy a domain box under the field, see Buy a domain for a site.
From an AI client over MCP
A connected AI client manages the same domains with the custom domain tools. get_domain_status and get_domain_connect_url need the config:read scope, and the tools that add or remove a domain need config:write. Every domain carries an _id, returned by get_domain_status and add_custom_domain, and the tools that act on one domain take it as domainId. While the domains are paused, get_domain_status answers with paused set to true and lists them as they are, without checking their DNS, and get_domain_connect_url is refused with Custom domains are paused until the workspace is on a paid plan again! For a domain the workspace bought on its Domains page, get_domain_status also returns OwnedDomain with its Id, Name, ManagedDns, Ready and Error. add_custom_domain refuses such a domain while its registration is not confirmed yet, and buy_domain connects a new domain to a site by itself when it is passed connectProjectId. Each domain also carries Verified, which is false while it still needs its ownership record, and get_domain_status lists that TXT record among its records. When a site in another workspace has the domain, add_custom_domain adds nothing and answers with a verification object holding the TXT record instead, and verify_domain finishes it once the record is in place. See Tokens and scopes.
Next
- DNS records lists the records and what each one does.
- Troubleshoot a domain covers a domain stuck on Pending.
- www and apex domains covers the second hostname of each domain and picking one canonical address.
- Manage DNS for a bought domain covers a domain the workspace bought on its Domains page.
- Publish a site is what a connected domain needs before it serves anything.