MkDocs is one of the greatest tools to document your software projects. Combined with the material theme, developers are able to build high-quality documentation websites in minutes. For example debugci.dev.

There is just one issue with this approach. At least for me. The theme uses Google Fonts and loads them from Google servers. A no-go under GDPR without the user’s consent.

There is an easy solution: the privacy plugin. However, it’s an insider feature and only available to paying supporters of the theme. I don’t criticize this approach, even open-source projects need funding. How to proceed if one doesn’t want to become an insider?

The theme provides a flag to disable Google fonts entirely and an option to inject custom stylesheets, for example, to load self-hosted fonts. Let’s do it step-by-step.

theme:
  fonts: false

extra_css:
- /main.css

Update 2023-12-18

The privacy plugin was released to the free tier in version 9.5.0.