Converting HTML to PDF using Rails

This page summarizes the projects mentioned and recommended in the original post on dev.to

SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
  1. Pdfkit

    A Ruby gem to transform HTML + CSS into PDFs using the command-line utility wkhtmltopdf (by pdfkit)

    A couple of popular gems to convert HTML to PDF in Rails are PDFKit and WickedPDF. They both use a command line utility called wkhtmltopdf under the hood; which uses WebKit to render a PDF from HTML.

  2. SaaSHub

    SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives

    SaaSHub logo
  3. Wicked Pdf

    PDF generator (from HTML) plugin for Ruby on Rails

    A couple of popular gems to convert HTML to PDF in Rails are PDFKit and WickedPDF. They both use a command line utility called wkhtmltopdf under the hood; which uses WebKit to render a PDF from HTML.

  4. Grover

    A Ruby gem to transform HTML into PDFs, PNGs or JPEGs using Google Puppeteer/Chromium

    The gem I recommend is called Grover. It uses Puppeteer and Chromium to "print" an HTML page into a PDF. So your PDF will look exactly how your page looks in Google Chrome's print preview. This will also allow you to reuse CSS from your app rather than having to write specific CSS just for your PDF exports.

  5. WKHTMLToPDF

    Discontinued Convert HTML to PDF using Webkit (QtWebKit)

    A couple of popular gems to convert HTML to PDF in Rails are PDFKit and WickedPDF. They both use a command line utility called wkhtmltopdf under the hood; which uses WebKit to render a PDF from HTML.

  6. puppeteer

    JavaScript API for Chrome and Firefox

    The gem I recommend is called Grover. It uses Puppeteer and Chromium to "print" an HTML page into a PDF. So your PDF will look exactly how your page looks in Google Chrome's print preview. This will also allow you to reuse CSS from your app rather than having to write specific CSS just for your PDF exports.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • Top 10 Test Automation Frameworks for JavaScript Developers (2025 Edition)

    2 projects | dev.to | 30 Oct 2025
  • Working with PDFs in Ruby

    4 projects | dev.to | 24 Oct 2023
  • How to use Playwright with GitHub Actions and GitHub Pages

    4 projects | dev.to | 30 Nov 2022
  • Solve network errors with PDFKit and wkhtmltopdf

    1 project | dev.to | 14 Jun 2022
  • Deploy a Web Scraper using Puppeteer, Node.js and Docker

    2 projects | dev.to | 24 Jan 2022

Did you know that Ruby is
the 13th most popular programming language
based on number of references?