Template for creating a custom Sphinx landing page
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Create a Landing Page for Sphinx

This is an example of how to customize Sphinx to create a custom landing page. This template provides a lot of freedoms, essentially the landing page is written with Jinja, giving you all the freedom to use HTML and CSS as you wish.

You need to do the following:

  • Move index.rst to contents.rst
  • Set master_doc = 'contents' in conf.py
  • Create an index.html in your _templates dir
  • Create a custom.css in your _static/css dir
  • Add a custom hook in your conf.py for CSS:
    def setup(app):
  • Create a custom hook in your conf.py to render index.html html_additional_pages = {'index': 'index.html'}

That's all. The code in source demonstrates how to do this.

This template's output is available at: https://sphinx-landing-template.readthedocs.io/en/latest/


Copyright (c) 2018, Mark Meyer (mark@ofosos.org)