Skip to content

Site Configuration

The main site configuration defines global settings for your entire website.

Core Settings

toml
# config.toml - Core site configuration
base_url     = "https://example.com"              # Site's base URL (required)
feed_url     = "https://example.com/atom.xml"     # RSS feed URL (auto-generated if not set)
title        = "My Site"                          # Site title (required)
description  = "Description for website"          # Site description for SEO
output_dir   = "public"                           # Output directory (default: "public")
language     = "en"                               # Default language code (default: "en")
theme        = "default"                          # Theme name (optional)
img          = "/img/default-cover.webp"          # Default sharing image
generate_feed = true                              # Generate RSS/Atom feed (default: false)

Configuration Options Reference

FieldTypeDefaultDescription
base_urlstringrequiredSite's base URL for absolute links
feed_urlstring{base_url}/atom.xmlRSS/Atom feed URL
titlestringrequiredSite title for pages and feeds
descriptionstring""Site description for SEO meta tags
languagestring"en"Default language code (ISO 639-1)
output_dirstring"public"Directory for generated static files
themestring""Theme name (if using themes)
imgstring""Default sharing image for social media
generate_feedbooleanfalseWhether to generate RSS/Atom feeds

Minimal Blog Configuration

toml
base_url = "https://myblog.com"
title = "My Blog"
description = "Thoughts and tutorials"
language = "en"

[extra]
name = "Author Name"
bio = "Writer and developer"

Complete Site Configuration

toml
base_url = "https://mysite.com"
feed_url = "https://mysite.com/feed.xml"
title = "Professional Portfolio"
description = "Software engineer and technical writer"
language = "en"
output_dir = "dist"
generate_feed = true

[extra]
name = "Jane Developer"
id = "janedev"
bio = "Full-stack developer with 10+ years experience"
avatar = "/img/profile.webp"
img = "/img/social-card.webp"

links = [
  { name = "GitHub", icon = "github", url = "https://github.com/janedev" },
  { name = "LinkedIn", icon = "linkedin", url = "https://linkedin.com/in/janedev" },
  { name = "Email", icon = "email", url = "mailto:[email protected]" },
]

sections = [
  { name = "blog", path = "/blog", is_external = false },
  { name = "projects", path = "/projects", is_external = false },
  { name = "speaking", path = "/speaking", is_external = false },
  { name = "about", path = "/about", is_external = false },
]

theme_config = {
  color_scheme = "auto",
  syntax_highlighting = true,
  show_reading_time = true,
  enable_toc = true
}

footer_copyright = "©2025 Jane Developer"
enable_analytics = true

Required Fields

Gozzi requires two fields in your site configuration:

  1. base_url - The full URL where your site will be hosted
  2. title - The name of your site

Without these fields, Gozzi will fail to build.

Best Practices

  1. Use HTTPS for base_url in production
  2. Keep descriptions concise - 150-160 characters optimal for SEO
  3. Set language code - Helps with SEO and accessibility
  4. Use consistent paths - End all URLs without trailing slashes
  5. Organize with [extra] - Keep custom data separate from core config

Related:

Released under the MIT License.