Masthead Documentation

Theme Manifest

Learn how the theme manifest describes your theme, exposes configuration and serves as the entry point for every Masthead theme.

Every Masthead theme starts with a manifest.json file.

The manifest is the entry point of a theme. It describes the theme, declares its configuration and tells Masthead how the theme should behave. Without a valid manifest, a theme cannot be previewed, packaged or uploaded.

A minimal manifest looks like this:

{
  "name": "My Theme",
  "slug": "my-theme",
  "version": "1.0.0",
  "author": "John Doe",
  "description": "A simple blog theme."
}

Theme information

The simplest part of the manifest describes the theme itself.

Field Description
name The human-readable name shown throughout Masthead.
slug A unique identifier used internally and by the marketplace.
version The current version of the theme.
author The author of the theme.
description A short description shown in the marketplace.

These values are primarily used to identify your theme and provide information to site owners.

Theme configuration

Besides describing the theme itself, the manifest also defines the configuration exposed to site owners.

Configuration is split into two categories:

  • Theme tokens, which define site-wide settings.
  • Global page metadata, which defines settings available to every page.

Both use the same field types and validation rules.

{
  "tokens": [...],
  "metadata": [...]
}

These sections are covered in detail in the following guides.

Validation

The manifest is validated whenever a theme is previewed, packaged or uploaded.

If the manifest contains invalid fields, duplicate keys or invalid configuration, Masthead reports the error and refuses to continue until the issue has been resolved.

This guarantees that a theme behaves the same during development and once installed.

Next steps

The manifest introduces two of the most important concepts in Masthead:

  • Theme tokens
  • Page metadata

The following guides explain how both systems work and how they can be used to build configurable themes.