mpdf/mpdf

PHP library generating PDF files from UTF-8 encoded HTML

View on GitHub ↗Jump to charts ↓Open shareable report →

Data as of . Signed-in members get hourly updates — create a free account.

Summary Information

Updated 1 hour ago
Type:Library / SDKCategory(s):Core & Utility LibrariesLanguages & Runtimes
Added to GitGenius on September 14th, 2026
Created on March 3rd, 2015
Open Issues & Pull Requests: 361 (+0)
GitHub issues: Enabled
Number of forks: 1,111
Total Stargazers: 4,706 (+0)
Total Subscribers: 142 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 11.7 hours
Mean response time: 154.6 days
90th percentile: 535.7 days
Tracked items: 97

Maintainer activity

1 person did triage or write work on this repository in the last 12 months.

Counts unlabeled, assigned, unassigned, milestoned, demilestoned, locked, unlocked over the last 12 months. These are issue and pull request events that require triage or write permission. Commits and code review are not counted. labeled and renamed are excluded because GitHub issue forms record the issue author as the actor. Figures from October 11, 2026. This count is not comparable across projects: each project's automation decides which of these events a person emits.

How this project is maintained

96% of open issues come from outside the core team, so the backlog reflects real-world use rather than internal planning. Work labelled "HTML/CSS support" is answered fastest, typically in about 12 hours, while "research needed" waits about 3 months. Three people close 96% of everything that gets resolved.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 55
New in 7 days: 1
Closed in 7 days: 0
Avg open age: 1,216 days
Stale 30+ days: 52
Stale 90+ days: 44

Recent activity

Opened in 7 days: 1
Closed in 7 days: 0
Comments in 7 days: 0
Events in 7 days: 0

Top labels

  • bug/fix (35)
  • help wanted (35)
  • feature/enhancement (20)
  • HTML/CSS support (13)
  • research needed (12)
  • fonts (6)
  • tables (6)
  • notices-warnings (5)

Most active issues this week

Sign in to see which issues are moving.
Sign in

Detailed Description

mPDF is a PHP library that generates PDF files from UTF-8 encoded HTML.

The library solves the problem of converting web content into portable PDF documents within PHP applications. It works by parsing UTF-8 encoded HTML and CSS, then rendering the content into PDF format. The tool is built on foundations from FPDF and HTML2FPDF, with enhancements for handling complex layouts, international character sets including CJK languages, and embedded resources like fonts and images.

Developers should choose mPDF for projects that need server-side PDF generation in PHP environments without external dependencies. It suits applications requiring support for multiple languages and character encodings, particularly those dealing with CJK content. The tool works best on production servers like nginx with php-fpm or Apache; single-threaded development servers such as php -S have known issues with fetching external HTTP resources. The README acknowledges that better alternatives exist outside the PHP ecosystem, which is relevant context for teams evaluating whether PHP-based PDF generation fits their architecture.

The project maintains broad PHP version support spanning from PHP 5.6 through PHP 8.5, with incremental updates adding compatibility for newer releases. Development occurs on a dedicated development branch separate from stable releases. The tool requires the mbstring and gd PHP extensions, with optional support for additional extensions including zlib for compression, bcmath for barcodes, and xml for character set conversion and SVG handling. Installation is managed through Composer via the official Packagist package.