Sectiondoc: Docstring section rendering sphinx extension

Build status Coverage status Documentation Status

The sectiondoc extension parses the function and class docstrings as they are retrieved by the autodoc extension and renders the section blocks into sphinx friendly rst. The extension shares similarities with alternatives (such as numpydoc) but aims at reflecting the original form of the docstring and support project specific customizations.

Key features of sectiondoc are:

  • Do not change the order of sections.
  • Allow sphinx directives between (and inside) section blocks.
  • Custom rendering styles


Sectiondoc should work with sphinx >= 0.4 that provides the autodoc-process-docstring hook.


The sectiondoc extension lives at Github. You can clone the repository using:

$ git clone


Install sectiondoc from pypi using pip:

$ pip install sectiondoc

Install the latest developing version using:

$ pip install git+


Styles can be selected by referencing in the module they are defined:

extensions = [

Indices and tables