How to install and use the theme
sphinx_rtd_theme package (or add it to your
$ pip install sphinx_rtd_theme
In your Sphinx project’s
conf.py file, add
sphinx_rtd_theme to the list of enabled extensions and as the active theme:
extensions = [
html_theme = "sphinx_rtd_theme"
Adding this theme as an extension is what enables localization of theme strings in your translated output. If these strings are not translated in your output, either we lack the localized strings for your locale, or you are using an old version of the theme.
How to upgrade
sphinx-rtd-theme to your project’s dependencies will make pip install the latest compatible version of the theme.
If you want to test a pre-release, you need to be explicit about the version you specify.
Otherwise, pip will ignore pre-releases. Add for instance
sphinx-rtd-theme==1.1.0b3 to test a pre-release.
We recommend that you pin the version of Sphinx that your project is built with.
We won’t release sphinx-rtd-theme without marking its compatibility with Sphinx. So if you do not pin
sphinx-rtd-theme itself, you will always get the latest compatible release.
More information is available in Read the Docs’ documentation on How to create reproducible builds.