autoclasstoc
Add a succinct TOC to auto-documented classes.
What it is and what it does
autoclasstoc is a Sphinx extension that adds a custom reStructuredText directive to generate a table of contents for Python classes. It solves the navigation problem that arises when using Sphinx's autodoc plugin: while autodoc fully documents every class member, it presents them sequentially without a summary, making it hard for users to understand what a class does or find specific methods. autoclasstoc inserts a collapsible TOC that groups methods into user-defined sections (e.g., public/private, by decorator, by prefix) and collapses inherited methods, so the documentation remains complete while staying navigable.
The package depends on Sphinx, docutils, and more_itertools. It is designed to integrate seamlessly with existing autodoc and autogen workflows. Maintenance is dormant and the license is undeclared, creating uncertainty about both long-term support and legal terms.
Use it for:
- Documenting large classes with many methods where a flat list is hard to navigate.
- Organizing class methods by category (public, private, special, inherited) in auto-generated docs.
- Collapsing inherited methods to highlight a class's own functionality while keeping full documentation.
- Integrating custom section logic into Sphinx autodoc workflows without manual TOC maintenance.
- Improving user experience in API documentation for complex Python libraries.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Generates a structured table of contents for auto-documented Python classes in Sphinx, organizing class members into meaningful sections while collapsing inherited methods to improve navigation.
Yes, if you are using Sphinx to document complex Python classes and want better navigation without manual TOC maintenance. The low install friction and lack of security vulnerabilities make it safe to try. However, the unclear license and dormant maintenance mean you should verify license compatibility upfront and be prepared to maintain a fork if critical bugs emerge. Not recommended for projects with strict license compliance requirements.
Install
autoclasstoc on PyPI
pip
pip install autoclasstocuv
uv add autoclasstocpoetry
poetry add autoclasstocInstalling autoclasstoc
Before you install
Low install friction with a pure-Python wheel. Dormant maintenance status means no recent updates, though the repository remains active and unarchived.
License in practice
License status is unclear—no SPDX identifier or raw license text is available in the package metadata, so you cannot verify licensing terms before use.
Quickstart
pip install autoclasstoc
In conf.py:
extensions = ['autoclasstoc']
In your .rst file:
.. autoclassoc:: mymodule.MyClass
Requires Sphinx and docutils; intended for use within a Sphinx documentation build, not as a standalone library.
Verify before relying
- Exact license terms—the package metadata does not declare a license, so legal compatibility is unknown.
- Whether the package works with current Sphinx versions—no changelog provided to confirm compatibility.
- Section customization options and API surface—the description mentions flexibility but does not detail configuration.
Package facts
| License | not declared (unclear) |
| Python support | supports the current Python release (>=3.6) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 3 — sphinx, docutils, more_itertools |
| Maintenance | dormant — 668 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 182,386/month — #10,100 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: autoclasstoc-1.7.0-py3-none-any.whl
Tags
More Sphinx packages
Parses Python docstrings in ReST, Google,…
permissive · top 1,000 on PyPI
SphinxSphinx generates professional documentation…
permissive · top 1,000 on PyPI
sphinxcontrib-serializinghtmlA Sphinx extension that outputs documentation…
permissive · top 1,000 on PyPI
alabasterAlabaster is a clean, responsive Sphinx theme…
permissive · top 1,000 on PyPI
sphinxcontrib-htmlhelpA Sphinx extension that generates HTML help…
permissive · top 1,000 on PyPI
sphinxcontrib-qthelpA Sphinx extension that converts documentation…
permissive · top 1,000 on PyPI
sphinx-autodoc2sphinx-autodoc2 generates API documentation for…
permissive · top 15,000 on PyPI
autodocsummA Sphinx extension that enhances autodoc with…
permissive · top 5,000 on PyPI
sphinx_external_tocA Sphinx extension that defines documentation…
permissive · top 15,000 on PyPI
sphinxcontrib-autoyamlA Sphinx extension that auto-generates…
permissive · top 15,000 on PyPI
sphinxcontrib-djangoA Sphinx extension that enhances autodoc output…
permissive · top 15,000 on PyPI
sphinx-autodoc-typehintsAutomatically extracts Python type hints from…
permissive · top 5,000 on PyPI
sphinx-autoapiSphinx AutoAPI generates complete API…
permissive · top 5,000 on PyPI
changelogA Sphinx extension that generates formatted…
permissive · top 15,000 on PyPI
autodoc_pydanticSphinx extension that automatically generates…
permissive · top 15,000 on PyPI
sphinxcontrib-typerA Sphinx extension that auto-generates…
permissive · top 15,000 on PyPI