Generated by GPT-5-mini| Sphinx (software) | |
|---|---|
![]() | |
| Name | Sphinx |
| Title | Sphinx (software) |
| Developer | Python Software Foundation, Georg Brandl, Eric Holscher |
| Released | 2008 |
| Programming language | Python |
| Operating system | Cross-platform |
| Genre | Documentation generator |
| License | BSD |
Sphinx (software) is a documentation generator written in Python that converts reStructuredText sources into multiple output formats. It is widely used by projects in the Python (programming language), Linux, OpenStack, and Django (web framework) ecosystems for producing HTML, PDF, and ePub manuals. Sphinx supports rich cross-referencing, theming, and extensibility through an ecosystem of extensions maintained by organizations such as the Python Software Foundation and contributors from projects like NumPy, Pandas (software), and SciPy.
Sphinx was created in 2008 by Georg Brandl to document the Python (programming language) project and later adopted by the Python Software Foundation; it grew alongside documentation efforts for CPython, Pyramid (web framework), and Twisted (software). Over time, Sphinx became central to documentation pipelines for scientific projects in the NumPy and SciPy stacks as well as infrastructure projects such as OpenStack and Kubernetes. Community contributions from maintainers of Django (web framework), Flask (web framework), and Read the Docs expanded themes, builders, and integrations, spurring adoption by companies like Red Hat, Microsoft, and Google. Major milestones include the addition of HTML5, JavaScript-based themes influenced by Bootstrap (front-end framework), and support for PDF output via integrations with LaTeX and XeTeX.
Sphinx provides a feature set tailored for technical documentation used by projects like NumPy, Pandas (software), SciPy, and Matplotlib: - Native parsing of reStructuredText used by Python (programming language) core documentation and projects in the Python Software Foundation ecosystem. - Automatic API documentation through autodoc-style directives used by Django (web framework), Flask (web framework), and Twisted (software) projects. - Multiple output formats including HTML, LaTeX/PDF, ePub, and man pages used by distributions such as Debian and Fedora. - Cross-references and indices that integrate with search tools originating from projects like Sphinx Search and third-party services such as Read the Docs. - Theming and localization features employed by international initiatives tied to organizations like Wikimedia Foundation and translations coordinated via Transifex.
Sphinx's architecture comprises a parser, a document tree, builders, and extensions; similar architectural patterns appear in projects such as Docutils and tools used by CPython documentation teams. The parser transforms reStructuredText into a document tree (doctree), then builders render outputs for HTML, LaTeX, and other formats—builders influenced by Jinja (template engine) and Pygments for syntax highlighting. Components include: - The core parser and doctree walker used by Docutils and CPython documentation pipelines. - Builders for HTML and LaTeX commonly used by projects like NumPy and SciPy. - The extension API that allows integrations with systems developed by organizations such as Read the Docs and GitHub. - Theme system leveraging templates and static assets similar to Bootstrap (front-end framework)-based sites and documentation portals run by Mozilla and Apache Software Foundation projects.
Typical workflows mirror continuous integration patterns adopted by Travis CI, GitHub Actions, and Jenkins: authors write reStructuredText, include autodoc directives referencing modules from CPython and third-party libraries like Requests (software), then build HTML or PDF artifacts. Projects such as Django (web framework), Flask (web framework), NumPy, and Pandas (software) use Sphinx in their documentation pipelines, often hosted on platforms like Read the Docs or integrated into deployment flows managed by GitHub and GitLab. Common steps: - Source authoring in reStructuredText used by Python (programming language) docs. - Local builds with Sphinx builders and previewing in browsers popularized by Mozilla developer documentation. - Continuous publishing to services such as Read the Docs or corporate documentation portals run by Red Hat or Microsoft.
Sphinx's extension ecosystem includes official and community extensions used across projects handled by organizations like the Python Software Foundation, NumPy community, and OpenStack: - Autodoc and napoleon extensions adopted by Google-style and NumPy-style docstring users. - Third-party extensions for math rendering integrating MathJax and LaTeX workflows leveraged by ArXiv authors and academic publishers. - Theme projects maintained by contributors affiliated with Read the Docs, Bootstrap (front-end framework), and the Mozilla documentation community. - Integrations with search and hosting platforms such as Read the Docs, GitHub Pages, and Netlify.
Sphinx is used by flagship projects and organizations including CPython, Django (web framework), NumPy, SciPy, Pandas (software), Matplotlib, OpenStack, and Kubernetes-adjacent documentation efforts. Major corporations and foundations employing Sphinx include the Python Software Foundation, Mozilla, Red Hat, Google, and Microsoft. Academic publishers and research repositories such as ArXiv-adjacent projects and university labs in the MIT and Stanford University communities also use Sphinx for reproducible documentation and textbooks.
Sphinx development is coordinated through open-source workflows common to projects hosted on GitHub and managed by maintainers associated with the Python Software Foundation; releases follow semantic versioning practices familiar to developers from CPython and NumPy. The software is distributed under a permissive BSD license, facilitating adoption by companies and foundations including Red Hat, Google, and Microsoft that require liberal licensing for redistribution.
Category:Documentation generators Category:Python (programming language) software