---
title: Custom Domains
description: Set up a custom domain for your documentation site.
icon: globe
---

# Custom Domains

Host your documentation at your own domain like `docs.yourcompany.com` instead of the default `yourproject-docs.syntext.dev`.

## Requirements

- Syntext Pro plan or higher
- Access to your domain's DNS settings

## Setup Process

### Step 1: Add Domain in Dashboard

1. Go to [Syntext Dashboard](https://syntext.dev/dashboard)
2. Select your project
3. Navigate to **Settings** → **Domains**
4. Click **Add Custom Domain**
5. Enter your domain: `docs.yourcompany.com`

### Step 2: Configure DNS

Add a CNAME record pointing to Syntext:

| Type | Name | Value |
|------|------|-------|
| CNAME | docs | `proxy.syntext.dev` |

<Note>
If you're using the root domain (e.g., `docs.com` instead of `docs.example.com`), you'll need to use an ALIAS or ANAME record. Not all DNS providers support this.
</Note>

### Step 3: Verify and Wait

1. Click **Verify Domain** in the dashboard
2. DNS propagation typically takes 5-30 minutes
3. Once verified, SSL is automatically provisioned

### Step 4: Deploy

After verification, deploy your docs:

```bash
stx deploy
```

Your docs are now live at your custom domain!

## DNS Provider Guides

### Cloudflare

1. Go to your domain's DNS settings
2. Add a CNAME record:
   - **Name**: `docs` (or your subdomain)
   - **Target**: `proxy.syntext.dev`
   - **Proxy status**: DNS only (gray cloud)

<Warning>
Disable Cloudflare's proxy (orange cloud) for the docs subdomain. Syntext handles SSL and CDN.
</Warning>

### AWS Route 53

1. Go to your hosted zone
2. Click **Create Record**
3. Configure:
   - **Record name**: `docs`
   - **Record type**: CNAME
   - **Value**: `proxy.syntext.dev`
   - **TTL**: 300

### Google Domains

1. Go to **DNS** settings
2. Scroll to **Custom records**
3. Add:
   - **Host name**: `docs`
   - **Type**: CNAME
   - **TTL**: 3600
   - **Data**: `proxy.syntext.dev`

### Namecheap

1. Go to **Advanced DNS**
2. Add new record:
   - **Type**: CNAME
   - **Host**: `docs`
   - **Value**: `proxy.syntext.dev`
   - **TTL**: Automatic

## SSL Certificates

SSL certificates are automatically provisioned and renewed:

- **Issuer**: Let's Encrypt
- **Validity**: 90 days
- **Renewal**: Automatic (30 days before expiry)
- **Type**: Wildcard not required (single domain)

No manual intervention needed.

## Multiple Domains

You can add multiple domains to one project:

- `docs.yourcompany.com` (primary)
- `developers.yourcompany.com` (alias)

All domains serve the same content.

## Redirects

### Redirect Old Domain to New

If migrating from another docs platform:

```json
{
  "redirects": [
    { "from": "olddomain.com/*", "to": "docs.yourcompany.com/:splat" }
  ]
}
```

### Redirect HTTP to HTTPS

Handled automatically. All HTTP requests redirect to HTTPS.

## Troubleshooting

### Domain Not Verifying

- Confirm CNAME record is correct
- Wait up to 48 hours for DNS propagation
- Check for conflicting records (A records, etc.)
- Ensure no CAA records are blocking Let's Encrypt

### SSL Certificate Error

- Domain must point to `proxy.syntext.dev`
- CAA records (if any) must allow `letsencrypt.org`
- Contact support if issues persist

### Mixed Content Warnings

Ensure all assets (images, scripts) use HTTPS URLs. Relative URLs are recommended:

```markdown
<!-- Good -->
![Screenshot](/images/screenshot.png)

<!-- Avoid -->
![Screenshot](http://example.com/screenshot.png)
```

## Removing a Custom Domain

1. Go to **Settings** → **Domains**
2. Click **Remove** next to the domain
3. Remove the DNS record from your provider

After removal, the site returns to `yourproject-docs.syntext.dev`.
