[Proposal] Add Document Auto-Conversion to PDF Block
See Github ticket. Please provide feedback before Jul 16, 2026.
TL;DR Summary
The PDF Block already provides native embedding and preview for PDF files. This proposal extends it with an optional conversion step, so common non-PDF document formats can be uploaded, converted to PDF, and embedded/previewed the same way, with a link to the original file for download.
Problem
The PDF Block allows for easy embedding of a PDF into a course. However, there is no way to embed or preview other common document formats (Word, Powerpoint, Excel, ODF, etc). For non-PDF formats, course authors currently have to either link the file for direct download (no preview), convert it to PDF manually before uploading (an extra step outside of the platform, breaking flow) or use a third-party embed service.
Use Cases
As a course author, I want one easy way to embed common document formats in to my course.
As an instructor, I want a way to have my learners preview documents they may not have software to view in full.
As a learner, I want to be able to view documents before deciding whether to download them for offline use.
Proposed Solution
We propose extending the PDF Block with an optional conversion feature, enabled by a systems operator through an official Tutor plugin. When enabled, the block uses Gotenberg, a self-hosted document conversion service, to convert uploaded documents to PDF for embedding and inline preview. This covers any format Gotenberg supports, including all common office document formats. The original source document remains available as a separate download link alongside the converted PDF embed.
Implementation Plan
The backend code for contacting Gotenberg and converting PDFs will be polished and contributed from this prototype branch of the original contributed PDF repository into its current home.
A Tutor plugin will be written to enable Gotenberg as a service to perform these conversions.
The Authoring MFE will be updated to enable this capability.
Our client is offering to sponsor the contribution of this change to the project and so this work is expected to be funded.
Long-term Ownership and Maintenance Plans
We anticipate that several teams will desire this functionality, and core contributors from OpenCraft will be actively involved in its development. These contributors will continue to assist with maintenance. If needed, one or more point persons can be designated as the primary contact for this code after its release.
Contact person
Fox Piacenti (fox at http://opencraft.com )
Other Approaches Considered
Creating separate embed tools for each document type would become quite unwieldy. If types are especially unique they might require installing plugins or running a large variety of in-browser tools, which would be difficult to manage.
Many operating systems can now support printing documents to PDF, but this requires awareness and extra steps from course authors, slowing down the course building process.
Competitive Research
Moodle uses a universal ‘File Embed’ module that allows you to upload a file. It can then select from different dispositions when displaying it:
The default choice presents a download link. An embedded view is selectable, however, if there is not a native tool for displaying this document (as is the case for many formats, including office documents,) this selection is ignored, and it just shows the file link:
@Fox Piacenti Thank you for this; it sounds like it would be a nifty addition!
I tried to find an example of Gotenberg in action (specifically what the user flow would look like to end users), but I couldn’t find anything. Could you point me in the right direction?