Configuration

Complete seite.toml reference — site settings, collections, build options, deployment, languages, and images.

Overview

All configuration lives in seite.toml at the project root. Here's a complete example:

[site]
title = "My Site"
description = "A personal blog and documentation"
base_url = "https://example.com"
language = "en"
author = "Jane Doe"

[[collections]]
name = "posts"
paginate = 10

[[collections]]
name = "docs"

[[collections]]
name = "pages"

[build]
output_dir = "dist"
minify = true
fingerprint = true

[deploy]
target = "github-pages"

[languages.es]
title = "Mi Sitio"
description = "Un blog personal"

[images]
widths = [480, 800, 1200]
quality = 80
webp = true
lazy_loading = true

[analytics]
provider = "google"
id = "G-XXXXXXXXXX"
cookie_consent = true

[site]

FieldTypeDefaultDescription
titlestringrequiredSite title, used in templates and meta tags
descriptionstring""Site description for SEO
base_urlstring"http://localhost:3000"Full base URL for canonical links, sitemap, RSS
languagestring"en"Default language code
authorstring""Author name for JSON-LD and RSS
Warning

Set base_url to your real domain before deploying. Leaving it as localhost will trigger a pre-flight warning and produce incorrect canonical URLs, sitemaps, and RSS feeds.

[[collections]]

Each [[collections]] entry defines a content collection. See Collections for full details.

[[collections]]
name = "posts"
label = "Blog"
directory = "posts"
url_prefix = "/posts"
default_template = "post.html"
has_date = true
has_rss = true
listed = true
nested = false
paginate = 10

[build]

FieldTypeDefaultDescription
output_dirstring"dist"Build output directory
data_dirstring"data"Directory for data files (YAML/JSON/TOML)
minifyboolfalseStrip CSS/JS comments and collapse whitespace
fingerprintboolfalseAdd content hash to asset filenames for cache busting
Tip

Enable minify for production builds — it strips CSS/JS comments and collapses whitespace for smaller files. Enable fingerprint when your CDN caches aggressively — content hashes in filenames ensure browsers always fetch the latest version.

When fingerprint = true, static files get hashed names (e.g., style.a1b2c3d4.css) and an asset-manifest.json is written to the output directory.

Data Files

Place YAML, JSON, or TOML files in the data/ directory to make structured data available in all templates as {{ data.filename }}.

Supported formats

ExtensionFormat
.yaml, .ymlYAML
.jsonJSON
.tomlTOML

Nested directories

Subdirectories create nested keys:

data/
  nav.yaml          → {{ data.nav }}
  authors.json      → {{ data.authors }}
  menus/
    main.yaml       → {{ data.menus.main }}
    footer.yaml     → {{ data.menus.footer }}

Theme integration

All bundled themes conditionally render data.nav for header navigation and data.footer for footer links and copyright. Example data/nav.yaml:

- title: Blog
  url: /posts
- title: About
  url: /about
- title: Docs
  url: /docs

Example data/footer.yaml:

links:
  - title: GitHub
    url: https://github.com/user/repo
  - title: Twitter
    url: https://twitter.com/user
copyright: "2026 My Company"

Conflict detection

The build will error if two data files share the same stem (e.g., authors.yaml and authors.json) or if a file and directory conflict (e.g., nav.yaml and nav/main.yaml). Unknown file extensions are skipped with a warning.

[deploy]

FieldTypeDefaultDescription
targetstring"github-pages"Deploy target: github-pages, cloudflare, netlify
repostringauto-detectedGit repository URL (GitHub Pages)
projectstringauto-detectedProject name (Cloudflare Pages)
auto_commitbooltrueAuto-commit and push before deploying. On non-main branches, auto-uses preview mode

[languages.*]

Optional. Add language sections to enable multi-language support:

[languages.es]
title = "Mi Sitio"
description = "Un blog personal y documentación"

[languages.fr]
title = "Mon Site"

Each language can override title and description. See Multi-language for details.

[images]

Optional. When this section is present, seite automatically processes images in static/. When omitted, images are copied as-is with no resizing or rewriting. New projects created with seite init include this section by default.

FieldTypeDefaultDescription
widthsarray[480, 800, 1200]Target widths in pixels for resized copies
qualityint80JPEG/WebP quality (1-100)
webpbooltrueGenerate WebP variants
lazy_loadingbooltrueAdd loading="lazy" to <img> tags

When configured, images in static/ are resized to each width, optionally converted to WebP, and <img> tags in HTML are rewritten with srcset and <picture> elements. To disable image processing, remove the [images] section entirely.

[analytics]

Optional. When present, analytics scripts are automatically injected into every HTML page during build. Supports Google Analytics 4, Google Tag Manager, Plausible, Fathom, and Umami.

FieldTypeDefaultDescription
providerstringrequiredAnalytics provider: google, gtm, plausible, fathom, umami
idstringrequiredMeasurement/tracking ID (e.g., G-XXXXXXX, GTM-XXXXX, domain, or site ID)
cookie_consentboolfalseShow a cookie consent banner and gate analytics on user acceptance
script_urlstringvariesCustom script URL (required for self-hosted Umami, optional for others)

Examples

Google Analytics 4 (direct):

[analytics]
provider = "google"
id = "G-XXXXXXXXXX"

Google Analytics 4 with cookie consent banner:

[analytics]
provider = "google"
id = "G-XXXXXXXXXX"
cookie_consent = true

Google Tag Manager:

[analytics]
provider = "gtm"
id = "GTM-XXXXXXX"
cookie_consent = true

Plausible Analytics (privacy-friendly, no cookies):

[analytics]
provider = "plausible"
id = "example.com"

Fathom Analytics:

[analytics]
provider = "fathom"
id = "ABCDEF"

Self-hosted Umami:

[analytics]
provider = "umami"
id = "abc-def-123"
script_url = "https://stats.example.com/script.js"
Tip

Privacy-respecting analytics like Plausible, Fathom, and Umami don't use cookies. You can typically use them without a consent banner (cookie_consent = false). Google Analytics and GTM set cookies and may require consent under GDPR/ePrivacy — set cookie_consent = true for those.

When cookie_consent = true, a fixed-position banner appears at the bottom of the page on the visitor's first visit. Analytics scripts only load after the visitor clicks "Accept". The choice is stored in localStorage so it persists across visits. The banner is fully accessible with role="dialog", keyboard-navigable buttons, and responsive design.

How it works

Analytics injection happens as a post-processing step after the main build. Every .html file in the output directory is rewritten:

  • Without consent: the analytics <script> tag is injected before </head>. GTM also gets a <noscript> fallback after <body>.
  • With consent: a consent banner with Accept/Decline buttons is injected before </body>. Analytics scripts are loaded dynamically only after the user accepts.

To remove analytics, delete the [analytics] section from seite.toml.

Frontmatter

Content files use YAML frontmatter between --- delimiters:

---
title: "Page Title"
date: 2026-02-18
updated: 2026-02-19
description: "Used in meta tags, OG, Twitter Cards, JSON-LD"
image: /static/preview.jpg
slug: custom-slug
tags:
  - rust
  - web
draft: true
template: custom.html
robots: noindex
extra:
  hero: true
  color: "#4361EE"
---
FieldTypeRequiredDescription
titlestringYesPage title
datedatePosts onlyPublication date (YYYY-MM-DD)
updateddateNoLast modified date
descriptionstringNoSEO description
imagestringNoSocial preview image
slugstringNoOverride auto-generated slug
tagslistNoContent tags
draftboolNoExclude from build unless --drafts
templatestringNoOverride default template
robotsstringNoPer-page robots directive
extramapNoArbitrary data for templates

seite-workspace.toml

For multi-site setups, a seite-workspace.toml at the workspace root configures all sites. Each site still has its own seite.toml.

[workspace]
name = "my-workspace"
shared_data = "data"           # Shared data directory (optional)
shared_static = "static"       # Shared static assets (optional)
shared_templates = "templates" # Shared templates (optional)

[[sites]]
name = "blog"
path = "sites/blog"
# base_url = "https://blog.example.com"  # Override site base_url
# output_dir = "dist/blog"               # Override output location

[[sites]]
name = "docs"
path = "sites/docs"

[cross_site]
unified_sitemap = false    # Combine all sites into one sitemap
cross_site_links = false   # Validate links across sites
unified_search = false     # Combined search index

See Workspaces for the full guide.

Next Steps

  • Collections — configure how posts, docs, and pages behave
  • Templates & Themes — use config values and data files in your templates
  • Deployment — deploy with the settings you've configured
  • Workspaces — manage multiple sites in a single repository