Guides

Retool PDF Exporter HTML Support: What to Do in 2024

OTC Team··4 min read
Retool PDF Exporter HTML Support: What to Do in 2024

If you've tried using PDF Exporter in Retool and quickly realized it only accepts Markdown, you've run into one of the most commonly requested missing features on the Retool community forum. The Retool PDF exporter HTML support request has been open since at least 2021, with dozens of upvotes and a steady stream of users hitting the same wall. This post explains exactly what the limitation is, why it matters, and what you can do about it today.

What Is the Retool PDF Exporter and What's Missing?

Retool's built-in PDF Exporter query lets you generate a PDF document directly from your Retool app without leaving the platform. The catch: it only supports Markdown as its content format. That means you're stuck with basic heading levels, bold, italics, and bullet lists — the standard Markdown toolkit. You cannot pass raw HTML into it.

For simple exports like a quick data summary or a plain report, Markdown is fine. But the moment you need to control font sizes precisely, create multi-column layouts, embed styled tables, or add branded headers and footers, Markdown falls completely short. As one community member put it, "the Markdown creates a huge font in the PDF and making a font smaller is not even possible." There's no workaround for that inside the native query.

Why Does HTML Matter for PDF Generation?

HTML gives you the full power of CSS — font sizing, colors, padding, borders, page breaks, and custom layouts. When you're building an internal tool that needs to output invoices, compliance reports, shipping manifests, or any document that has to look professional, Markdown simply can't get you there. HTML-to-PDF is the industry standard approach precisely because it maps directly to how browsers already render content, making layout predictable and controllable.

The Retool community has made this case clearly. The core asks are:

  • Passing an HTML string directly into the PDF Exporter query
  • CSS-level font and spacing control in generated PDFs
  • Support for tables, nested elements, and custom page structure
  • No dependency on third-party APIs just to get a styled document

Is Retool HTML PDF Export on the Roadmap?

As of the latest update from Retool staff in the community thread, HTML support for the PDF Exporter is not on the immediate roadmap. A Retool team member confirmed they want to support it but advised users to explore the external API route in the meantime. This has been the status for some time, so it's worth planning around rather than waiting on.

Workarounds: How to Export HTML as PDF from Retool Today

While native support is pending, there are real options. Here's how to approach HTML-based PDF generation from Retool right now:

Option 1: Use an External HTML-to-PDF API

Services like PDFShift, HTML/CSS to PDF by API2PDF, or Gotenberg accept an HTML payload and return a PDF binary. You can call these from a Retool REST API resource query. The basic flow looks like this:

  • Build your HTML string in a JavaScript query or inline using Retool's {{ }} templating
  • POST the HTML to your chosen API endpoint with your API key in the headers
  • Receive the PDF as a binary or Base64 response
  • Use a Download File utility or file component to deliver it to the user

This approach gives you full HTML and CSS control. The downside is cost — most of these APIs charge per conversion — and the added complexity of managing an external dependency.

Option 2: Self-Host a PDF Microservice

If you want to avoid per-conversion pricing, you can spin up a lightweight self-hosted service using Puppeteer (Node.js) or WeasyPrint (Python). Both accept HTML and output PDF. Deploy it on a small server or container, then call it from Retool just like any other REST resource. This is a one-time engineering investment that eliminates ongoing API costs and keeps your data internal — important for compliance-sensitive use cases.

Option 3: Iframe + Browser Print (Low-Fidelity Fallback)

For very simple cases, you can load an HTML page in a Retool IFrame component and trigger window.print() via a JavaScript query. This relies on the user's browser print dialog and is not truly automated PDF generation, but it requires zero external dependencies and works surprisingly well for basic formatted outputs.

What to Do While You Wait for Native Support

If Retool's native PDF Exporter HTML support is important to your team, the most actionable steps are:

  • Vote on the community thread — Retool uses community signals to prioritize the roadmap
  • Use a self-hosted Puppeteer service if data privacy or cost is a concern
  • Use a third-party API if you need something working today with minimal setup
  • Avoid rebuilding your entire PDF logic in Markdown — you'll likely need to redo it once HTML is supported

The bottom line: Retool's PDF Exporter is a useful starting point, but its Markdown-only limitation is a real constraint for production internal tools. Until native Retool PDF exporter HTML support lands, a self-hosted or API-based HTML-to-PDF solution is the most reliable path forward. Build it as a standalone resource in Retool and you'll be able to swap it out cleanly once the native feature ships.

Ready to build?

We scope, design, and ship your Retool app — fast.

Ready to ship your first tool?