sphinx-autodoc2
Analyse a python project and create documentation for it.
Decision gist · record as of 2026-08-14
Yes. sphinx-autodoc2 is a solid choice if you need automatic API documentation for Python packages. It has low install friction, active maintenance, no known vulnerabilities, permissive licensing, and solves real pain points (static analysis, Markdown support, `__all__` handling) that motivated its creation. The 991-day gap since the last release is offset by recent repository activity, suggesting the project is stable rather than abandoned.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python >= 3.8 and a working Sphinx documentation setup.
- Low install friction with three lightweight runtime dependencies (astroid, tomli, typing-extensions).
- Active maintenance with recent commits; last release was 991 days ago but repository remains actively developed.
License · maintenance · safety
permissive license (permissive) — Licensed under MIT (permissive), so you can use and modify the package freely in both open-source and proprietary projects with minimal restrictions.
last release 2023-11-27 (991 days) · last repo commit 2026-08-10 · 100 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 305,085 downloads/mo, #7,799 on PyPI
Alternatives
Verify before relying
pip install sphinx-autodoc2
# In conf.py:
extensions = ['sphinx_autodoc2']
# In your Sphinx documentation, reference the autodoc2 directive to generate API docs from your Python package.- Whether the package handles complex type annotations (e.g., generics, unions) correctly in all Python versions it claims to support.
- Performance characteristics when analyzing very large packages or deeply nested module hierarchies.
- Compatibility with recent Sphinx versions beyond what the fact sheet indicates.
What it is and what it does
sphinx-autodoc2 is a Sphinx extension that generates API documentation by analyzing Python code statically, without needing to import or install the target package. It parses source files directly using astroid, extracts docstrings (supporting both reStructuredText and Markdown), and respects `__all__` declarations to document only the public API. The analysis and rendering are decoupled, so you can use it outside Sphinx via a command-line tool.
The extension is optimized for development workflows through caching of analysis and rendering, and correctly handles Python typing constructs like `if TYPE_CHECKING` blocks. It supports mixed docstring formats within the same project and offers extensive configuration options. Three runtime dependencies (astroid, tomli, typing-extensions) keep the install footprint small, and the codebase uses type annotations and function-based rendering instead of complex templates.
Use it for
- Generate API documentation for a Python package without installing it, useful for documenting packages from external sources or avoiding dependency conflicts.
- Migrate documentation from reStructuredText to Markdown docstrings incrementally while maintaining both formats in the same project.
- Build documentation in a CI/CD pipeline where caching speeds up rebuilds during development iterations.
- Document only the public API by leveraging `__all__` declarations, keeping generated docs focused and maintainable.
- Analyze and document packages outside of Sphinx using the standalone autodoc2 command-line tool.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
sphinx-autodoc2 is a solid choice if you need automatic API documentation for Python packages. It has low install friction, active maintenance, no known vulnerabilities, permissive licensing, and solves real pain points (static analysis, Markdown support, `__all__` handling) that motivated its creation. The 991-day gap since the last release is offset by recent repository activity, suggesting the project is stable rather than abandoned.
Install
sphinx-autodoc2 on PyPI
Before you install
Low install friction with three lightweight runtime dependencies (astroid, tomli, typing-extensions). Active maintenance with recent commits; last release was 991 days ago but repository remains actively developed.
Requires Python >= 3.8 and a working Sphinx documentation setup.
License in practice
Licensed under MIT (permissive), so you can use and modify the package freely in both open-source and proprietary projects with minimal restrictions.
Quickstart
pip install sphinx-autodoc2
# In conf.py:
extensions = ['sphinx_autodoc2']
# In your Sphinx documentation, reference the autodoc2 directive to generate API docs from your Python package.
Verify before relying
- Whether the package handles complex type annotations (e.g., generics, unions) correctly in all Python versions it claims to support.
- Performance characteristics when analyzing very large packages or deeply nested module hierarchies.
- Compatibility with recent Sphinx versions beyond what the fact sheet indicates.
Package facts
| License | permissive license permissive |
| Python support | Supports the current Python release >=3.8 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 3 packagesastroidtomlityping-extensions |
| Maintenance | Actively maintained 991 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 305,085 / month, #7,799 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Framework :: Sphinx :: ExtensionLicense :: OSI Approved :: MIT LicenseProgramming Language :: Python :: 3 |
Evidence: sphinx_autodoc2-0.5.0-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
An agent finds packages by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language. Give your agent the search over MCP.
More Sphinx packages
Parses Python docstrings in ReST, Google, Numpydoc, and Epydoc formats, extracting structured information like descriptions, parameters, return types, and exceptions.
Install it if you need to programmatically read and extract structured data from Python docstrings.
Sphinx generates professional documentation from reStructuredText source files, producing HTML, PDF, EPUB, and other formats with automatic cross-references, code highlighting, and hierarchical navigation.
A Sphinx extension that outputs documentation in serialized HTML formats (JSON and pickle) alongside standard HTML.
Alabaster is a clean, responsive Sphinx theme for documentation that requires Python 3.10 or newer and Sphinx 6.2 or newer.
A Sphinx extension that generates HTML help files from reStructuredText documentation source.
A Sphinx extension that converts documentation source files into QtHelp format, enabling integration with Qt-based help systems and documentation viewers.
However, be aware that maintenance is dormant—if you rely on it long-term, monitor Sphinx compatibility and consider whether QtHelp remains the right format for your…
See also autoclasstoc · sphinx-autoapi · sphinx-automodapi · sphinx-autodoc-typehints · sphinxcontrib-autoyaml · sphinxcontrib-apidoc · sphinxcontrib-django · sphinx-jinja · sphinx-markdown-tables · m2r2