PHPackages                             phug/compiler - 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. [Templating &amp; Views](/categories/templating)
4. /
5. phug/compiler

ActiveLibrary[Templating &amp; Views](/categories/templating)

phug/compiler
=============

Pug (ex-Jade) compiler for PHP, HTML template engine structured by indentation

2.0.1(3mo ago)488.9k↓25.6%15MITPHPPHP &gt;=5.5.0

Since Mar 15Pushed 3mo ago2 watchersCompare

[ Source](https://github.com/phug-php/compiler)[ Packagist](https://packagist.org/packages/phug/compiler)[ Docs](http://phug-lang.com)[ GitHub Sponsors](https://github.com/kylekatarnls)[ Fund](https://opencollective.com/pug-php)[ RSS](/packages/phug-compiler/feed)WikiDiscussions master Synced yesterday

READMEChangelog (10)Dependencies (8)Versions (136)Used By (5)

Phug Compiler
=============

[](#phug-compiler)

What is Phug Compiler?
----------------------

[](#what-is-phug-compiler)

The Phug compiler get pug string or a pug file then return a PHP compiled template.

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

[](#installation)

Install via Composer

```
composer require phug/compiler
```

Usage
-----

[](#usage)

```
$compiler = new Phug\Compiler($options);
$phtml = $compiler->compile($pugInput);

//$phtml is the PHP compiled template
```

###  Health Score

56

—

FairBetter than 97% of packages

Maintenance79

Regular maintenance activity

Popularity33

Limited adoption so far

Community23

Small or concentrated contributor base

Maturity76

Established project with proven stability

 Bus Factor1

Top contributor holds 94.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 ~33 days

Recently: every ~235 days

Total

99

Last Release

110d ago

Major Versions

0.5.26 → 1.0.12019-10-06

1.12.3 → 2.0.02025-03-07

### Community

Maintainers

![](https://www.gravatar.com/avatar/df90c422f521bf26355c3e185a59fe7afb35531af56244dfaec03ee1d0ca6f24?d=identicon)[kylekatarn](/maintainers/kylekatarn)

![](https://www.gravatar.com/avatar/75a80e0830e63c723808d021d3a1648a2643db60f4ac2e40842da05f227f956b?d=identicon)[TorbenKoehn](/maintainers/TorbenKoehn)

---

Top Contributors

[![kylekatarnls](https://avatars.githubusercontent.com/u/5966783?v=4)](https://github.com/kylekatarnls "kylekatarnls (269 commits)")[![TorbenKoehn](https://avatars.githubusercontent.com/u/1403556?v=4)](https://github.com/TorbenKoehn "TorbenKoehn (15 commits)")[![carusogabriel](https://avatars.githubusercontent.com/u/16328050?v=4)](https://github.com/carusogabriel "carusogabriel (1 commits)")[![rodion-k](https://avatars.githubusercontent.com/u/2526460?v=4)](https://github.com/rodion-k "rodion-k (1 commits)")

---

Tags

phphtmltemplatecompilerjadeviewsrenderpugphtmlpresentationdialectphug

### Embed Badge

![Health badge](/badges/phug-compiler/health.svg)

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

###  Alternatives

[phug/phug

Pug (ex-Jade) facade engine for PHP, HTML template engine structured by indentation

66301.0k14](/packages/phug-phug)[talesoft/tale-pug

A clean, lightweight and easy-to-use templating engine for PHP based on Pug, formerly Jade

319.5k3](/packages/talesoft-tale-pug)[talesoft/tale-jade

A clean, lightweight and easy-to-use templating engine for PHP based on Jade/Pug

8819.3k5](/packages/talesoft-tale-jade)[figdice/figdice

Template Engine, XML-centric and attribute-driven

212.4k1](/packages/figdice-figdice)

PHPackages © 2026

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