Skip to content

Python Package GitHub branch checks state status codecov Code Style: Black Language grade: Python PyPI - Python Version PyPI



Automatic source link generation for mkdocstrings


mkdocstrings-sourcelink is a source link generator for mkdocstrings, which allows connecting the source code to a repository independent of the host (GitHub, GitLab, own Services).

The original idea of mkdocstrings-sourcelink was coming from keras-autodoc and used as inspiration. However, this implementation focuses on using straight mkdocstrings and not rephrase docstrings into the documentation. Furthermore, mkdocstrings-sourcelink also allows:

  1. Generating API list
  2. Using templates and examples
  3. Importing existing markdown files like


pip install mkdocstrings-sourcelink


The usage requires just three steps:

  1. ❯ python
  2. ❯ mkdocs.yml
  3. ❯ mkdocs deploy

Last update: November 9, 2021