Pydoc-Markdown is a command-line tool designed to generate Python API documentation in Markdown format. Rather than executing Python code like traditional documentation generators, it parses code using docspec, a specialized parser that extracts documentation information without running the code. This approach provides a safer and more efficient way to generate documentation for Python projects.
The tool supports multiple documentation styles including Sphinx, Google, and Pydoc-Markdown's own specific format, automatically converting docstrings to properly formatted Markdown output. A notable capability is its ability to parse docstrings for variables through docspec, which recognizes both comment blocks prefixed with #: and string literals following statements. The tool also generates cross-references between API objects according to documentation syntax conventions, such as linking to other classes or functions within the generated documentation.
Configuration flexibility is a core feature of Pydoc-Markdown. Users can define their documentation generation settings using either YAML files or pyProject.toml configuration files, allowing for standardized setup across different project types. The tool can then generate complete Markdown documentation with a single command. Installation is straightforward via pipx, with support for Python 3.7 and later, regardless of the Python version requirements of the package being documented.
Recent development has shifted toward integration with Novella, a static site generator backend. Starting with version 4.6.0, the project began focusing on Novella integration as a replacement for tool-specific renderers previously built directly into Pydoc-Markdown. This integration enables users to embed generated API documentation inline within existing Markdown files using @pydoc tags, providing tighter coupling with static site generators like MkDocs and Hugo. However, recognizing user preferences, version 4.7.0 officially un-deprecated YAML configuration support, committing to maintain this approach alongside the newer Novella integration.
The repository shows active maintenance with the primary contributor NiklasRosenstein handling the majority of development activity tracked by GitGenius, along with contributions from lraubuch and Hocnonsense. Issue and pull request response times are notably fast, with a median latency of zero hours. The most common tracked issues involve bug reports and feature requests, indicating ongoing refinement of the tool's capabilities.
Several notable projects rely on Pydoc-Markdown for their API documentation generation, including CosmPy, haystack by deepset, tensorchord/envd, and tqdm. The tool's adoption across these diverse projects demonstrates its effectiveness in handling various documentation requirements. The repository maintains connections with other significant open-source projects through overlapping contributors, including chroma-core/chroma, apollographql/apollo-client, and stanfordnlp/dspy, suggesting its relevance within the broader Python development ecosystem.
The maintainer has noted in the README that time constraints limit active development, recommending mkdocstrings as an alternative for users specifically seeking MkDocs integration. Despite this caveat, the project continues to receive updates and maintains community support through GitHub Discussions for user questions and assistance.