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

> ## Agent Instructions
> These are the docs for Sevalla, a platform for deploying applications, databases, static sites, object storage and load balancers. The dashboard is at https://app.sevalla.com.
> Bold text in steps is an exact dashboard label.
> To act on a Sevalla account, prefer the Sevalla MCP server (https://mcp.sevalla.com/mcp, see https://docs.sevalla.com/ai-agents/overview.md), then the Sevalla CLI (https://docs.sevalla.com/developer-tools/cli.md), then the REST API (https://api-docs.sevalla.com, OpenAPI spec at https://api.sevalla.com/v3/openapi.json).
> Every page index is at https://docs.sevalla.com/llms.txt.

# Create a static site

> Create a static site from a private or public Git repository: every field of the create form, the defaults Sevalla fills in, the cost summary and the first deployment.

Creating a static site connects a Git repository to Sevalla, sets how the site is built, and starts its first deployment right away. The site's free `<name>.sevalla.page` domain starts serving it as soon as that deployment succeeds.

## Before you begin

* The company has billing details and a valid payment method on the [Billing](https://app.sevalla.com/billing) page. Static sites are free up to the [monthly allowances](/static-sites/overview#pricing-and-free-allowances), but the dashboard asks for both before you create any service.
* For a private repository, you have a GitHub, GitLab or Bitbucket account with access to it. You connect it during the steps; see [Git providers](/git/overview).
* You can create static sites in the company, or in the project you'll put the site in. See [Users and roles](/company/users-and-roles).
* The company has fewer than 100 static sites.

## Create the static site

<Steps>
  <Step title="Open the create form">
    In the sidebar, click **Static sites**, then click **Create static site**. If the company has no static sites yet, click **Create a static site**.
  </Step>

  <Step title="Choose the source">
    Under **Source**, click **Private repository** for a repository on your GitHub, GitLab or Bitbucket account, or **Public repository** for any public Git URL.
  </Step>

  <Step title="Pick the repository and branch">
    For a private repository, click the **Git provider** (**GitHub**, **GitLab** or **Bitbucket**). If it isn't connected yet, click **Connect to GitHub** (or GitLab, Bitbucket), finish in the new tab, and the form picks up the connection. Choose the **Repository** and the **Branch**.

    For a public repository, enter the **Repository URL**, for example `https://github.com/acme/shop-site`, and the **Branch**.
  </Step>

  <Step title="Choose how it deploys">
    For a private repository, leave **Auto-deploy** on to deploy every push to the branch. Turn on **Pull request previews** to build a preview of every other branch you push.
  </Step>

  <Step title="Name the site">
    Under **Details**, check the **Name**. It starts as the repository's name. If your company has projects, choose a **Project**.
  </Step>

  <Step title="Check the build settings">
    Under **Build settings**, check the **Build command** and **Publish directory**. When Sevalla recognizes the framework, it fills them in and shows **Framework detected** with its name. If the repository already holds the finished files, turn off **Build site before publishing**.
  </Step>

  <Step title="Add environment variables">
    Optional. Under **Environment variables**, add the keys and values the build needs, or click **Import .env**.
  </Step>

  <Step title="Create it">
    Check the summary and the estimated cost, then click **Create static site**.
  </Step>
</Steps>

The site opens on its **Overview** tab and its first deployment starts. When the deployment shows **Deployed**, the site's status changes to **Live**: click **Visit site** to open it. To follow the build, click the deployment under **Recent deployments**; see [Deployments](/static-sites/deployments).

## Form fields

### Source

| Field | What it is | Default |
| - | - | - |
| Source | **Private repository** (GitHub, GitLab or Bitbucket) or **Public repository** (any public Git URL) | **Private repository** |
| **Git provider** | Private repositories only: **GitHub**, **GitLab** or **Bitbucket**. Switching provider clears the repository and branch. | **GitHub** |
| **Repository** | Private repositories only: a repository from your connected account. For GitHub, **Adjust GitHub repository access** opens GitHub, where you choose which repositories Sevalla can read. | None |
| **Repository URL** | Public repositories only: the repository's URL. A URL on `gitlab.com` is a GitLab repository, `bitbucket.org` is Bitbucket, anything else is GitHub. | None |
| **Branch** | The site's default branch: what manual and automatic deployments use. | `main` or `master` for a private repository, `main` for a public one |
| **Auto-deploy** | Private repositories only: deploy every push to the branch. See [automatic deployments](/static-sites/deployments#deploy-automatically-on-push). | On |
| **Pull request previews** | Private repositories only: deploy every push to another branch to its own preview URL. See [pull request previews](/static-sites/deployments#pull-request-previews). | Off |

A site built from a public repository can't deploy automatically or preview branches: deploy it by hand. You can switch it to a private repository later with [Update source](/static-sites/settings#source).

### Details

| Field | What it is | Rules |
| - | - | - |
| **Name** | The display name in the dashboard. It follows the repository you pick until you type your own. | Required |
| **Project** | Shown when the company has projects: the project the site belongs to, or **None (company level)**. | Required if you can create static sites only inside projects |

Sevalla also derives the site's permanent name from the display name: lowercase, special characters and leading digits removed, spaces turned into hyphens, cut to 27 characters, plus a random suffix. For example, **Acme shop** becomes `acme-shop-k3x9p`, and the site's default domain is `acme-shop-k3x9p.sevalla.page`. You can [update the display name](/static-sites/settings#details) later; the permanent name never changes.

### Build settings

| Field | What it is | Default |
| - | - | - |
| **Build site before publishing** | Run an install and a build command before publishing. Turn off to publish the repository's files as they are. | On |
| **Node version** | The Node.js version for the build: **Latest LTS**, **Latest release**, **Node 22**, **Node 20**, **Node 18** or **Node 16**. | **Latest LTS** |
| **Build command** | The command that builds the site. Required while the build is on. | `npm run build` |
| **Root directory** | The folder the build runs in, relative to the repository root. Empty is the repository root. | Empty |
| **Publish directory** | The folder with the finished site, relative to the root directory. Empty publishes the root directory itself. | Empty |
| **Index file** | The file served for `/` and for folder URLs. | `index.html` |
| **Error file** | Optional: a file served for paths that have no file, such as `404.html`. | Empty |

For a private repository, Sevalla reads `package.json` on the chosen branch and fills in the build command, publish directory and Node version for the frameworks it recognizes. See [Framework detection](/static-sites/build-settings#framework-detection) for the list, and [Build settings](/static-sites/build-settings) for what each field does.

<Warning>
  With the build on and the **Publish directory** empty, Sevalla publishes the whole root directory after the build, source files included (except `.git`, `node_modules` and `.env` files). Set the publish directory to your build's output folder, such as `dist`.
</Warning>

### Environment variables

Add a **Key** and a **Value** per row. Click **Add another** for more rows, click **Import .env** to load a `.env` file, or paste a `.env` file's contents into a key field. With **Pull request previews** on, choose whether the variables apply to **Production**, **Preview** or both (both are selected). Without previews, the variables apply to production. See [Environment variables](/static-sites/environment-variables).

### Summary

The summary card shows the **Source**, **Branch**, **Name**, **Project** (when the company has projects) and **Build** command, the estimated monthly cost, and the company's payment method. The estimate is \$0.00: bandwidth up to 100 GB and builds up to 600 minutes a month are free per company, and the card lists the price beyond each allowance, tax included.

## What happens next

* The first deployment of the default branch starts as soon as the site exists. It shows on the **Overview** and **Deployments** tabs with the trigger **Manual**.
* Git LFS is on, pretty URLs are off, and every push to the default branch deploys (no deploy paths). Change these on the [Settings](/static-sites/settings) tab.
* The `<name>.sevalla.page` domain starts serving the site when its first deployment succeeds. To add your own domain, see [Custom domains](/domains/overview).

If creating the site fails with `Repository not found for URL "<url>"`, Sevalla can't read the repository: check the URL of a public repository, or grant Sevalla access to the private one. See [Troubleshoot static sites](/static-sites/troubleshooting#repository-not-found).

## API and CLI

| Task | API | CLI |
| - | - | - |
| Create a static site | [Create static site](https://api-docs.sevalla.com/v3/static-sites/create-static-site) | `sevalla static-sites create --name "Acme shop" --repository https://github.com/acme/shop-site --branch main` |
| List static sites | [List static sites](https://api-docs.sevalla.com/v3/static-sites/list-static-sites) | `sevalla static-sites list` |
| Get a static site | [Get static site](https://api-docs.sevalla.com/v3/static-sites/get-static-site) | `sevalla static-sites get <id>` |

The API also accepts an install command, deploy paths and a project; the CLI accepts deploy paths (`--allow-deploy-paths`, `--ignore-deploy-paths`) and a project (`--project`). Both start the first deployment automatically, like the dashboard.


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