Deploying Zensical on Read the Docs

Zensical is a modern static site generator designed to simplify building and maintaining project documentation. It’s built by the creators of Material for MkDocs and shares the same core design principles and philosophy – batteries included, easy to use, with powerful customization options.

Minimal configuration is required to build an existing Zensical project on Read the Docs:

.readthedocs.yaml
 version: 2

 build:
 os: ubuntu-24.04
 tools:
     python: latest
 jobs:
   # We recommend using a requirements file for reproducible builds.
   # This is just a quick example to get started.
   # https://docs.readthedocs.io/page/guides/reproducible-builds.html
   install:
     - pip install zensical
   build:
     html:
       - zensical build
   post_build:
     - mkdir -p $READTHEDOCS_OUTPUT/html/
     - cp --recursive site/* $READTHEDOCS_OUTPUT/html/

Quick start

Configuring Zensical and Read the Docs Addons

There are some additional steps you can take to configure your Zensical project to work better with Read the Docs.

Set the canonical URL

A canonical URL allows you to specify the preferred version of a web page to prevent duplicated content.

Set your Zensical site URL to your Read the Docs canonical URL using a Read the Docs environment variable:

zensical.toml
[project]
# Note: variable interpolation is not yet supported in Zensical configuration files,
# so you can use the explicit value for now.
site_url = "https://your-project.readthedocs.io/"

Example repository and demo

Example repository

https://github.com/readthedocs/test-builds/tree/zensical

Demo

https://test-builds.readthedocs.io/en/zensical/

Further reading