freedomofpress/dangerzone

Take potentially dangerous PDFs, office documents, or images and convert them to safe PDFs

Python

5,784

2,079 commits

updated Oct 12, 2026

See the code

README

Dangerzone

Take potentially dangerous PDFs, office documents, or images and convert them to a safe PDF.

SettingsConverting

Dangerzone works like this: You give it a document that you don't know if you can trust (for example, an email attachment). Inside of a sandbox, Dangerzone converts the document to a PDF (if it isn't already one), and then converts the PDF into raw pixel data: a huge list of RGB color values for each page. Then, outside of the sandbox, Dangerzone takes this pixel data and converts it back into a PDF.

Read more about Dangerzone in the official site.

Getting started

The documentation lives at docs.dangerzone.rocks. Its source is under docs/ in this repository:

Preview the site locally with poetry install --with docs followed by make docs-serve.

License and Copyright

Licensed under the AGPLv3: https://opensource.org/licenses/agpl-3.0

Copyright © 2022–2024 Freedom of the Press Foundation and Dangerzone contributors
Copyright © 2020–2021 First Look Media

See also THIRD_PARTY_NOTICE.md for more information regarding the third-party software that Dangerzone depends on.

freedomofpress/dangerzone

Take potentially dangerous PDFs, office documents, or images and convert them to safe PDFs

Python

5,784

2,079 commits

updated Oct 12, 2026

See the code

README

Dangerzone

Take potentially dangerous PDFs, office documents, or images and convert them to a safe PDF.

SettingsConverting

Dangerzone works like this: You give it a document that you don't know if you can trust (for example, an email attachment). Inside of a sandbox, Dangerzone converts the document to a PDF (if it isn't already one), and then converts the PDF into raw pixel data: a huge list of RGB color values for each page. Then, outside of the sandbox, Dangerzone takes this pixel data and converts it back into a PDF.

Read more about Dangerzone in the official site.

Getting started

The documentation lives at docs.dangerzone.rocks. Its source is under docs/ in this repository:

Preview the site locally with poetry install --with docs followed by make docs-serve.

License and Copyright

Licensed under the AGPLv3: https://opensource.org/licenses/agpl-3.0

Copyright © 2022–2024 Freedom of the Press Foundation and Dangerzone contributors
Copyright © 2020–2021 First Look Media

See also THIRD_PARTY_NOTICE.md for more information regarding the third-party software that Dangerzone depends on.

Significant stargazers

(top 24 of 66)

Roman Bachmann

69 followers · starred Mar 2020

Greg Weber

228 followers · starred Mar 2020

Juan Calderon-Perez

208 followers · starred Sep 2024

Carl Schwan

114 followers · starred Sep 2023