PHPackages                             qdequippe/phpdftk - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [PDF &amp; Document Generation](/categories/documents)
4. /
5. qdequippe/phpdftk

ActiveLibrary[PDF &amp; Document Generation](/categories/documents)

qdequippe/phpdftk
=================

PHP wrapper for pdftk

1.0.0(11mo ago)04.5k[2 PRs](https://github.com/qdequippe/phpdftk/pulls)MITPHPPHP ^8.3CI passing

Since May 22Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/qdequippe/phpdftk)[ Packagist](https://packagist.org/packages/qdequippe/phpdftk)[ RSS](/packages/qdequippe-phpdftk/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (10)Dependencies (6)Versions (12)Used By (0)

PHPDFTK
=======

[](#phpdftk)

[![CI](https://github.com/qdequippe/phpdftk/actions/workflows/ci.yml/badge.svg)](https://github.com/qdequippe/phpdftk/actions/workflows/ci.yml)[![Latest Stable Version](https://camo.githubusercontent.com/b0104ef7d5997cf464c751548e3021d0f45ddbefccf6c1f17694eb5bb757ebe5/68747470733a2f2f706f7365722e707567782e6f72672f7164657175697070652f7068706466746b2f762f737461626c65)](https://packagist.org/packages/qdequippe/phpdftk)[![License](https://camo.githubusercontent.com/6d8fbaed76445c698c03e0f196d8ebbaefe7f06694408a9cbf58de111c87d627/68747470733a2f2f706f7365722e707567782e6f72672f7164657175697070652f7068706466746b2f6c6963656e7365)](https://packagist.org/packages/qdequippe/phpdftk)[![codecov](https://camo.githubusercontent.com/91eb79c03c67a5812eab627399a674e6a5afa2d11f5648f9416c0d286128b2a2/68747470733a2f2f636f6465636f762e696f2f67682f7164657175697070652f7068706466746b2f67726170682f62616467652e7376673f746f6b656e3d4d4c4f52343342563937)](https://codecov.io/gh/qdequippe/phpdftk)

PHP wrapper for [PDFtk](https://www.pdflabs.com/tools/pdftk-the-pdf-toolkit/).

Inspired by [Kevsoft.PDFtk](https://github.com/kevbite/Kevsoft.PDFtk) and [pypdftk](https://github.com/revolunet/pypdftk).

Installation
------------

[](#installation)

To install, use composer:

```
composer require qdequippe/phpdftk

```

Requirements
------------

[](#requirements)

- [PDFtk Server](https://www.pdflabs.com/tools/pdftk-server/) installed (see below installation based on your OS)

### Linux (Ubuntu)

[](#linux-ubuntu)

See  (similar on other distributions).

```
apt-get install pdftk

```

### MacOS

[](#macos)

```
brew install pdftk-java

```

Usage
-----

[](#usage)

For example, to fill input PDF’s form fields with the data from an FDF file or XFDF file.

```
$pdftk = new \Qdequippe\PHPDFtk\PDFtk();

$filledPdf = $pdftk->fillForm(
    pdfFilePath: 'path_to_pdf.pdf',
    formDataFilePath: 'path_to_form_data.fdf', // or XFDF file,
    flatten: true,
);

// $filledPdf = PDF filled with form data
```

Testing
-------

[](#testing)

```
./vendor/bin/phpunit

```

License
-------

[](#license)

The MIT License (MIT). Please see [License File](./LICENSE) for more information.

Resources
---------

[](#resources)

-
-
-

###  Health Score

44

—

FairBetter than 92% of packages

Maintenance73

Regular maintenance activity

Popularity22

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 93.1% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

11

Last Release

357d ago

Major Versions

0.9.1 → 1.0.02025-05-26

### Community

Maintainers

![](https://www.gravatar.com/avatar/131a1ad4ca05898c6f3224ae01ad7d7118a3bc41b455f631a6be50660eceffe2?d=identicon)[qdequippe](/maintainers/qdequippe)

---

Top Contributors

[![qdequippe](https://avatars.githubusercontent.com/u/3193300?v=4)](https://github.com/qdequippe "qdequippe (27 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (2 commits)")

---

Tags

fdfpdfpdftkphpxfdf

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/qdequippe-phpdftk/health.svg)

```
[![Health](https://phpackages.com/badges/qdequippe-phpdftk/health.svg)](https://phpackages.com/packages/qdequippe-phpdftk)
```

###  Alternatives

[spatie/browsershot

Convert a webpage to an image or pdf using headless Chrome

5.2k32.1M102](/packages/spatie-browsershot)[ismaelw/laratex

A package for creating PDFs in Laravel using LaTeX

12730.1k](/packages/ismaelw-laratex)[rockett/weasyprint

A feature-rich Laravel wrapper for the WeasyPrint Document Factory.

28199.7k](/packages/rockett-weasyprint)[padam87/rasterize-bundle

HTML to PDF Symfony bundle. Works with Puppeteer, PhantomJS, and more.

1579.4k](/packages/padam87-rasterize-bundle)[enzim/tika-wrapper

This is a simple PHP Wrapper for Apache Tika (using the tika-app jar)

6021.3k](/packages/enzim-tika-wrapper)[karkowg/php-mupdf

Minimal PDF to image converter using MuPDF

202.8k](/packages/karkowg-php-mupdf)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
