# SebastiaanKlippert/go-wkhtmltopdf

Golang commandline wrapper for wkhtmltopdf

Repository: https://github.com/SebastiaanKlippert/go-wkhtmltopdf
Canonical: https://ross.abutalabs.com/products/go-wkhtmltopdf
Language: Go
License: MIT
License Family: permissive
Topics: wkhtmltopdf, pdf-document, go, golang, pdf-generation, html-to-pdf, pdf, html
Last push: 2025-10-30T22:05:21+00:00

## Health v2 (maintenance only)
Score: 45/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 49, release rhythm 8, longevity 100
- inputs: {"age_days": 3938, "days_push": 307, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1181, forks 159 (observed 2026-08-28T04:03:53.651494+00:00)

## What it is
A pure Go wrapper around the wkhtmltopdf command-line utility for generating PDF documents from HTML/CSS templates. It exposes all wkhtmltopdf options as typed struct members and manages option ordering, input pages, and output buffers for server-side use.

## Use cases
- generate pdf invoices from html templates in go
- convert html to pdf from a golang server
- create pdf reports with tables and images from html/css
- render html pages to pdf programmatically
- generate pdfs from http(s) urls in go
- produce print-quality pdfs with css print media

## When to choose
- you need to generate PDFs from HTML/CSS templates in a Go application
- you want type-safe access to wkhtmltopdf options with IDE completion
- you need to combine multiple HTML documents into one PDF with per-page options
- you want to feed input via io.Reader and capture output in a buffer or io.Writer

## When to avoid
- starting a new project, since wkhtmltopdf itself is archived and unmaintained
- you need a pure-Go PDF renderer with no external binary dependency
- you need actively developed HTML-to-PDF features or modern CSS support
- your environment cannot install the wkhtmltopdf command-line tool

## Facets
- artifact type: library
- maturity: maintenance
- function: pdf, templating
- domain: pdf, web-development, developer-tools
- platform: windows, go
- tags: wkhtmltopdf, html-to-pdf, pdf-generation, go-wrapper, command-line-wrapper, linux, macos

## Member repositories
- SebastiaanKlippert/go-wkhtmltopdf (main) score 45

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:03:53.651494+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T06:25:00.466636+00:00, confidence not recorded.
  - readme: https://github.com/SebastiaanKlippert/go-wkhtmltopdf (fetched 2026-08-28T04:03:53.651494+00:00, sha fb488710779d)
- Data as of 2026-08-30T08:39:29.467469+00:00.
