> ## Documentation Index
> Fetch the complete documentation index at: https://www.lettercamp.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Custom domains

> Connect a custom hostname to Lettercamp, verify DNS and HTTPS, and manage an existing address.

Give your Lettercamp publication a custom hostname, such as `blog.example.com`.
For an address under an existing website path, use [Subfolder hosting](https://www.lettercamp.com/docs/publishing/subfolders.md).

Run `domain` from the same publication folder after its first deployment. The CLI
uses that folder's deployment site. No site-selection flags are required.

## Connect a hostname

```bash theme={null}
npx lettercamp domain blog.example.com
```

The CLI prints the exact CNAME and TXT records to add at your DNS provider. Add
them, then press Enter to check ownership, DNS, and HTTPS. Keep the CNAME unproxied
(DNS only). The CLI prints additional verification records if they become available.

Custom hostnames such as `blog.example.com` and `www.example.com` are supported.
Connecting an apex domain such as `example.com` directly is not supported yet.
The `my-blog.lettercamp.site` address is assigned when you create the site and
requires no DNS setup.

## Check, resume, or disconnect

```bash theme={null}
npx lettercamp domain
npx lettercamp domain remove
```

With no address, `domain` shows the current connection or resumes unfinished setup.
Verification waits up to ten minutes before asking you to run it again; your setup
is saved. A connected site can use one custom hostname or one subfolder at a time.
Remove the existing connection before adding a different one.

`domain remove` asks for confirmation and returns the site to its Lettercamp
address. For subfolders, wait for disconnection to finish before removing the
proxy rules from your existing website.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.