Pandoc Celebrates 20 Years as the Universal Document Converter

The universal document converter celebrates its 20th birthday with support for dozens of input and output formats, filters, templates, citations, and more.

The open-source tool Pandoc, widely used for converting documents from one markup format to another and into publishing formats, is celebrating its 20th birthday.

The initial version was released on August 3, 2006, and came with the GPL license. Pandoc 0.1 consisted of about 3,000 lines of Haskell code and was capable of converting documents between Markdown, reStructuredText, HTML, and LaTeX, as well as generating RTF and S5 output.

But as often happens in open-source circles, what started out as a personal project aimed at learning Haskell later became one of the language’s best-known applications.

Even though it is frequently just called a document converter, Pandoc is more properly speaking a programmable document-processing system. It includes readers that convert input formats into a common abstract syntax tree, and writers that produce the desired output format from that internal representation.

Pandoc’s modular architecture does not require a separate converter for each possible pair of formats; once a reader and a writer have been added, that format can take part in a number of different conversion combinations. Moreover, users have the possibility of altering the structure of the intermediate document using custom filters and the built-in support for Lua scripting.

The software currently supports a large number of markup, word-processing, academic, presentation, and publishing formats, such as Markdown, HTML, LaTeX, DOCX, ODT, EPUB, AsciiDoc, reStructuredText, Org Mode, Typst, Jupyter Notebook, PowerPoint, DocBook, JATS, and a number of wiki and bibliography formats.

The project has also moved well beyond simple text conversion. Pandoc is capable of producing citations and bibliographies, handling mathematical expressions, using templates and reference documents, creating presentations and electronic books, and can thus serve as the basis for automated publishing workflows.

MacFarlane, the project’s creator, states that over 200 versions of Pandoc have been released in the last twenty years, and its four main packages now include over 85,000 lines of Haskell code, without counting the tests, whereas more than 600 people have contributed to the project and 7,346 GitHub issues have been dealt with.

The latest version 3.9 included a new major feature, which was the ability to compile the application to WebAssembly. As a result, it became possible to run a version that is largely fully featured directly in a web browser without having to send the documents to a remote server.

The article also touches on the AI debate. Although MacFarlane admits that AI systems can already translate between certain document formats, he maintains that Pandoc still has several important advantages: its much lower energy requirements, its predictable output, and its more reliable conversions.

In any case, at the moment, Pandoc remains one of the most versatile publishing tools in the open-source community. It is both a command-line program and a Haskell library that can convert a single structured document into a variety of formats, such as a website or a manual page, a Word file, an academic paper, a presentation, or an electronic book.

For more information about Pandoc’s history, see John MacFarlane’s official 20th-anniversary retrospective, and the project’s source code is available in its official GitHub repository.

Bobby Borisov

Bobby Borisov

Bobby, an editor-in-chief at Linuxiac, is a Linux professional with over 20 years of experience. With a strong focus on Linux and open-source software, he has worked as a Senior Linux System Administrator, Software Developer, and DevOps Engineer for small and large multinational companies.

Leave a Reply

Your email address will not be published. Required fields are marked *