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

# Custom Domain (CNAME) Configuration

> Configure a custom branded domain for UniBee hosted checkout and billing pages

# Custom Domain Configuration (CNAME) Guide

By configuring a Custom Domain (Custom Branding), you can replace UniBee's default hosted page URL with your own branded domain (e.g., `checkout.yourdomain.com`), providing a seamless and professional experience for your customers.

***

## 1. What is a CNAME?

A **CNAME (Canonical Name)** record is a type of DNS record that maps an alias name (your subdomain) to a true or canonical domain name (UniBee's server).

* **Simple Analogy**: Think of a CNAME as a "pointer." When a user visits `checkout.yourdomain.com`, the DNS record tells their browser to actually fetch the content from UniBee's servers.
* **Restriction**: CNAME records must be set on a **subdomain** (e.g., `checkout` or `billing`) and cannot be applied to a root domain (e.g., `yourdomain.com`).

***

## 2. Benefits of Using a Custom Domain

Setting up a CNAME record offers several key advantages:

* **Brand Consistency**: Maintain your brand identity throughout the entire customer journey, from landing page to checkout.
* **Increased Conversion**: Users are more likely to complete a purchase when they see a familiar domain in the address bar, reducing friction and bounce rates.
* **Improved Tracking**: Custom domains simplify the setup of tracking pixels (like Facebook Pixel or Google Analytics) by keeping everything under a "First-Party" context.
* **Enhanced Security**: Combined with SSL proxying, your custom domain ensures all transactions remain encrypted and secure.

***

## 3. Common Use Cases

* **SaaS Platforms**: Use `billing.yoursoftware.com` for customer subscription management.
* **E-commerce**: Use `pay.yourstore.com` for a branded checkout experience.
* **Environment Testing**: Use separate subdomains for testing and production to avoid data pollution.

***

## 4. How to Get Your Configuration

Depending on which mode you are currently using in the UniBee dashboard, record the following values:

| Configuration Item | **Test Mode**                        | **Live Mode**                            |
| :----------------- | :----------------------------------- | :--------------------------------------- |
| **Record Type**    | CNAME                                | CNAME                                    |
| **Host/Name**      | Your chosen subdomain (e.g., `test`) | Your chosen subdomain (e.g., `checkout`) |
| **Value/Target**   | **`cs-sandbox.unibee.app`**          | **`cs.unibee.app`**                      |

***

## 5. Recommended: Configuration via Cloudflare

<Note>
  UniBee does not directly manage SSL certificates for custom domains. To ensure your domain is accessible via HTTPS, we strongly recommend using **Cloudflare** as your DNS provider to benefit from their SSL Proxy features.
</Note>

### Why Cloudflare?

* **Automatic SSL**: Cloudflare provides free Universal SSL certificates, removing the need for manual certificate management.
* **Enhanced Security**: Benefit from Cloudflare's WAF and DDoS protection.
* **Global Performance**: Speed up your checkout page loading times via Cloudflare's global Edge network.

### Cloudflare Setup Steps

1. **Add Record**: Log in to Cloudflare, go to **DNS > Records**, and click **Add Record**.
2. **Enter Details**:
   * **Type**: Select `CNAME`.
   * **Name**: Enter your subdomain (e.g., `checkout`).
   * **Target**: Paste the Value provided in the UniBee dashboard (`cs-sandbox.unibee.app` for Test or `cs.unibee.app` for Live).
   * **Proxy status**: **Must be enabled (Orange Cloud icon)**. This is required for SSL support.
3. **Configure SSL/TLS**:
   * Go to the **SSL/TLS** tab in Cloudflare.
   * Set the encryption mode to **Full** or **Full (Strict)**.
4. **Verify & Activate**:
   * Return to the UniBee **Custom Branding** page and click **Verify & Save Domain**.
   * Test the generated **Checkout Link** to ensure it loads correctly under your new domain.

***

<Note>
  DNS propagation can take up to **24-48 hours** to complete worldwide.
</Note>
