# Deployment

## Deployment Guide

**Files:** `src/config/config.toml`, `netlify.toml`, `vercel.json`, `vercel.sh`, `wrangler.toml` · **Skill level:** Beginner

`npm run build` makes a static site in the `dist/` folder, which any static host can serve. Settings are included for **Netlify**, **Vercel**, and **Cloudflare Pages**. To use another host, see [Astro's deployment guides](https://docs.astro.build/en/guides/deploy/).

### Before You Deploy
Set your site's address in `baseUrl` under `[site]` in `src/config/config.toml`. It still holds the theme's demo address, and nothing warns you about it. Canonical links, the sitemap, `robots.txt`, `llms.txt`, and social previews use it. A `SITE_URL` environment variable overrides it for a build.

Use a Node.js version your edition supports, as listed under `engines` in `package.json`: 22.12.0 or later for Astro and Sanity, and 22.23.4 or later for Tina.

Then go through this list, in every language. Most of these hold sample values, and nothing warns you about them:

- **Business info:** `contactInfo` in each `src/i18n/<lang>.json`, and the offices in `src/content/sections/<language>/office-locations.md`.
- **Forms:** `contactFormAction` and `contactFormProvider`, and `formAction` in `[settings.subscription]`. See [Contact Form](../customization/contact/) and [Subscription](../customization/subscription/).
- **Analytics:** add your tags to `[head]` in `config.toml`, and replace or remove the sample Umami line.
- **Sample content:** prices, testimonials, customer logos, figures, team members, integrations, jobs, changelog entries, blog posts, and photos.
- **Identity:** `title`, `tagline`, and `description` in `[site]`, `brandName` in `[settings]`, and `footer` in `src/i18n/<lang>.json`.
- **Legal pages:** the placeholder privacy policy and terms in `src/content/pages/<language>/`.
- **Branding:** your logo, favicons, social sharing image, colors, and fonts. See [Site Identity & Logo](../customization/site-identify-logo/) and [Fonts & Colors](../customization/fonts-colors/).

Your `README.md` has this list for your edition, with the Tina and Sanity labels.

### Netlify
The included `netlify.toml` sets the build command (`npm run build`), the `dist` folder, Node.js 22, cache headers, and a "page not found" rule for `/fr/` and `/ar/`.

1. Create a new site on [Netlify](https://www.netlify.com/).
2. Connect your Git repository.
3. Netlify reads its settings from `netlify.toml` and deploys your site.

### Vercel
The included `vercel.json` sets the trailing slash and the sitemap redirect. The included `vercel.sh` script builds your site with your Vercel project's address, which overrides `baseUrl`.

1. Create a new project on [Vercel](https://vercel.com/).
2. Connect your Git repository.
3. Vercel reads its settings from `vercel.json` and deploys your site.

### Cloudflare Pages
1. Create a new project on [Cloudflare Pages](https://pages.cloudflare.com/).
2. Connect your Git repository.
3. Set the build command to `npm run build` and the output folder to `dist`.
4. Set the Node.js version with a `NODE_VERSION` environment variable, using a version your edition supports.

The included `wrangler.toml` names the project `stella-astro` and sets `NODE_VERSION`, so change its `name` if you deploy with Wrangler (`npm run deploy:cf`). Wrangler isn't installed with the theme, so install it first.

### Headers And Missing Pages
The included `public/_headers`, `vercel.json`, and `public/.htaccess` serve the `.md` and llms files as text, and keep the `.md` copies out of search results. On any other host, set the same headers yourself. See [AI Links & llms](../features/ai-links-llms/).

Only `netlify.toml` includes a "page not found" rule for each language. On other hosts, a missing `/fr/` or `/ar/` address may show the default language's 404 page unless you add a rule. When you add or remove a language on Netlify, change its block in `netlify.toml`. See [Internationalization](../customization/internationalization/).

### Tina Edition
The site builds and works with no account and no variables. To edit online, add `PUBLIC_TINA_CLIENT_ID` and `TINA_TOKEN` to your host. We have not run online editing against a live Tina Cloud project, so try one save on a copy of your site first. See [Tina](../features/tina/).

### Sanity Edition
Add `PUBLIC_SANITY_PROJECT_ID`, `PUBLIC_SANITY_DATASET`, and `PUBLIC_SANITY_STUDIO_URL` to your host. Without a project ID, the site builds from the bundled demo content. The site must rebuild to show content you publish. In this edition, set your address under **Site settings > Site > Base URL**. A `SITE_URL` on your host overrides it, but a `SITE_URL` line in `.env` doesn't.

We have not deployed this edition on these hosts. See [Sanity](../features/sanity/).

<Aside type="caution">
  Don't set `SANITY_API_READ_TOKEN` or `SANITY_VISUAL_EDITING` on your static
  host. Online preview needs a separate Node.js server.
</Aside>