{"id":9254,"library":"python-docs-theme","title":"Python Docs Theme","description":"The Sphinx theme for the CPython docs and related projects. It provides a clean, responsive design and includes features like a dark mode, code copy buttons, and internationalization support. The library is actively maintained with frequent releases, typically on a monthly or bi-monthly cadence. The current version is 2026.3.","status":"active","version":"2026.3","language":"python","source_language":"en","source_url":"https://github.com/python/python-docs-theme/","tags":["Sphinx","documentation","theme","CPython"],"install":[{"cmd":"pip install python-docs-theme","lang":"bash","label":"Install latest version"}],"dependencies":[{"reason":"Required Python interpreter version for the package.","package":"python","optional":false},{"reason":"The theme is built for Sphinx documentation projects.","package":"Sphinx","optional":false}],"imports":[{"note":"This setting is placed in your Sphinx project's conf.py file to activate the theme.","symbol":"html_theme","correct":"html_theme = 'python_docs_theme'"}],"quickstart":{"code":"mkdir my_docs\ncd my_docs\nsphinx-quickstart  # Follow prompts, choose 'y' for separate source/build, 'y' for autodoc\n\n# Edit source/conf.py (or conf.py directly if not using separate source/build)\n# Add or modify the following line:\n# html_theme = 'python_docs_theme'\n\n# Create a simple reStructuredText file (e.g., source/index.rst)\n# .. toctree::\n#    :maxdepth: 2\n#    :caption: Contents:\n#\n#    intro\n\n# Create source/intro.rst\n# My First Page\n# ============\n#\n# Hello, world! This is my first page using the Python Docs Theme.\n\nmake html  # or sphinx-build -b html source build\n","lang":"bash","description":"A basic Sphinx project setup, demonstrating how to enable the `python-docs-theme`. After running `sphinx-quickstart` to create your project structure, edit `conf.py` to set the `html_theme`."},"warnings":[{"fix":"Upgrade your Python environment to 3.12 or newer, or pin `python-docs-theme<2025.4`.","message":"Version 2025.4 and newer dropped support for Python 3.10 and 3.11.","severity":"breaking","affected_versions":">=2025.4"},{"fix":"Upgrade your Sphinx installation to 7.3 or newer, or pin `python-docs-theme<2025.4`.","message":"Version 2025.4 and newer requires Sphinx 7.3 or newer.","severity":"breaking","affected_versions":">=2025.4"},{"fix":"Upgrade to `python-docs-theme` 2026.2 or newer to ensure full copy button functionality for all code blocks, including shell and console examples.","message":"The behavior of code block copy buttons was enhanced across versions. Initially, they appeared on hover/click (2025.5), then specifically enabled for shell sessions and consoles (2026.2).","severity":"gotcha","affected_versions":"<2026.2"},{"fix":"If encountering unexpected layout issues, temporarily comment out or unset these theme-related configurations in `conf.py` to see if they are causing the conflict.","message":"Custom configurations for `html_sidebars`, `html_theme_path`, or `html_theme_config` in `conf.py` can interfere with the theme's default layout and features.","severity":"gotcha","affected_versions":"All"}],"env_vars":null,"search_vec":"'2026.3':54 'activ':36 'bi':47 'bi-month':46 'button':29 'cadenc':49 'clean':17 'code':27 'copi':28 'cpython':9,58 'current':51 'dark':25 'design':19 'doc':2,10 'document':56 'featur':22 'frequent':39 'includ':21 'internation':31 'librari':34 'like':23 'maintain':37 'mode':26 'month':44,48 'project':13 'provid':15 'python':1 'relat':12 'releas':40 'respons':18 'sphinx':5,55 'support':32 'theme':3,6,57 'typic':41 'version':52","created_at":"2026-04-16T18:49:16.020551+00:00","updated_at":"2026-04-16T18:49:16.020551+00:00","problems":{"verify_error":"no import statement found"},"ecosystem":"pypi","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":"2026.4","cli_name":"","cli_version":null,"type":"library","homepage":null,"github":"https://github.com/python/python-docs-theme","docs":null,"changelog":null,"pypi":"https://pypi.org/project/python-docs-theme/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["web-framework"],"base_url":null,"auth_type":null,"provenance":{"verified_status":"skip","verified_at":"2026-06-28","last_verified":"2026-06-28","next_check":"2026-07-05","install_tag":null}}