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

# Hosting

> Deploy applications to embd.co with branch previews, production promotion, and custom domains

Embeddables Hosting deploys a Worker application and its static assets to `embd.co`. Every deploy
gets an immutable commit URL and a moving branch URL. Deploys from the app's production branch also
update its production URL.

## Set up a project

<Steps>
  <Step title="Choose the project slug">
    Open **Hosting** in the Embeddables dashboard and enroll the project. The project slug must be
    3–16 characters: lowercase letters, numbers, and single hyphens.

    The slug becomes part of every `embd.co` hostname for the project. It cannot be changed after it
    has been set, so choose a durable value.
  </Step>

  <Step title="Register an app">
    Add an app in the dashboard. Its slug must be 3–12 characters and follows the same lowercase
    rules as the project slug. An app slug cannot be changed.

    Set the production branch to the branch that should deploy automatically to production. It
    defaults to `main`. The repository path is optional.
  </Step>

  <Step title="Create a deploy key">
    Create a project deploy key and save the returned `edk_…` value as the
    `EMBEDDABLES_DEPLOY_KEY` secret in your CI provider.

    <Warning>
      The plaintext secret is returned only when the key is created. Listing keys later returns
      metadata, not the secret.
    </Warning>
  </Step>

  <Step title="Deploy from CI">
    Add the [Embeddables Deploy action](/hosting/deploy-from-ci). It uploads the app and returns the
    branch and commit preview URLs.
  </Step>
</Steps>

## Hostnames

For project slug `acme` and app slug `storefront`:

| Target | Example |
| - | - |
| Production | `https://storefront---acme.embd.co` |
| Branch preview | `https://feature-checkout-a1b2c3---storefront---acme.embd.co` |
| Commit preview | `https://1a2b3c4---storefront---acme.embd.co` |

Branch names are converted to DNS-safe labels and include a short hash. Commit URLs use the first
seven characters of the commit SHA. Use the URLs returned by a deploy instead of constructing them.

## Production behavior

A successful deploy creates or reuses its immutable commit URL. It updates the moving branch URL
unless that branch already serves a newer commit. When the git branch matches the app's production
branch, the same deploy also points production at that commit unless production already serves a
newer commit.

You can manually promote any existing preview, including an older commit for rollback. The
production `embd.co` hostname and every active [custom domain](/hosting/custom-domains) move
together.

## Manage hosting programmatically

* Use the [Admin SDK reference](/hosting/admin-sdk) to build hosting controls into an operator
  dashboard.
* Use the [MCP reference](/hosting/mcp) to manage hosting from an MCP client.


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