Auto-generates API documentation for Python 3 projects from modules, packages and docstrings with no special configuration.
numpy/numpydoc
A Sphinx extension that parses NumPy-style docstrings and renders them into structured API documentation.
- Stars
- 354
- Forks
- 184
- Open issues
- 135
- Last commit
- 6 days ago
What is it?
numpydoc is a Sphinx extension for handling docstrings written in the NumPy documentation format. It converts sections such as Parameters, Returns, Raises and Examples into properly formatted Sphinx output, so Python projects can keep one consistent docstring style across their codebase.
Beyond docstring parsing, the extension adds code description directives such as np:function and np-c:function, which document functions and C APIs in the NumPy style. The NumPy docstring guide included with the project explains how to write docstrings that work with the extension.
The package requires Python 3.10 or newer and Sphinx 6 or newer.
Key features
- 01Parses NumPy-style docstring sections such as Parameters, Returns and Raises.
- 02Adds np:function and np-c:function directives for documenting code objects.
- 03Integrates with Sphinx as a standard extension.
Use cases
- Generating API reference documentation for a Python library that uses NumPy-style docstrings.
- Documenting C extension functions with the np-c directives alongside Python APIs.
Things to know
- The license could not be identified from the repository metadata, so check the LICENSE file before reuse.
In collections
Topics
FAQ
- What is numpydoc?
- A Sphinx extension that parses NumPy-style docstrings and renders them into structured API documentation. numpydoc is a Sphinx extension for handling docstrings written in the NumPy documentation format. It converts sections such as Parameters, Returns, Raises and Examples into properly formatted Sphinx output, so Python projects can keep one consistent docstring style across their codebase.
- Is numpydoc free to use? What license does it have?
- numpydoc is open source under the Other license. Check the license terms before using it in commercial products.
- Is numpydoc still maintained?
- Actively maintained. The last commit to numpydoc was on Nov 1, 2026.
- What can I use numpydoc for?
- Generating API reference documentation for a Python library that uses NumPy-style docstrings. Documenting C extension functions with the np-c directives alongside Python APIs.
- Where can I get numpydoc?
- The source code and installation instructions are on GitHub: https://github.com/numpy/numpydoc
Summary generated by AI from the project's README. GitHub stats refresh daily.
Related projects
A Python CLI that measures how many functions, classes, methods and modules in a codebase have docstrings, with CI-friendly pass/fail thresholds.
Command-line tool that generates markdown API documentation from Google-style Python docstrings, as a lighter alternative to Sphinx.
Python documentation generator that builds HTML, PDF, EPUB and other output from reStructuredText or Markdown sources.
A Sphinx plugin that brings Doxygen-generated C/C++ API documentation into reStructuredText and Sphinx docs.
A command-line tool that watches a Sphinx documentation directory, rebuilds the docs on changes, and reloads the browser via a local server.