PHPackages                             figdice/figdice - 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. figdice/figdice

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

figdice/figdice
===============

Template Engine, XML-centric and attribute-driven

3.3.1(6y ago)212.4k3[2 issues](https://github.com/figdice/figdice/issues)[1 PRs](https://github.com/figdice/figdice/pulls)1MITPHPPHP &gt;=5.4CI failing

Since Apr 27Pushed 4mo ago1 watchersCompare

[ Source](https://github.com/figdice/figdice)[ Packagist](https://packagist.org/packages/figdice/figdice)[ Docs](http://www.figdice.org/)[ RSS](/packages/figdice-figdice/feed)WikiDiscussions 4.x Synced today

READMEChangelog (10)Dependencies (2)Versions (21)Used By (1)

[![Logo](https://camo.githubusercontent.com/c8c27f8c1d06eb8886d5cf2027009f61cf14d5533cabe91591cbd8cb31e0fbc4/687474703a2f2f7777772e666967646963652e6f72672f696d672f6669672d3133302d31362e706e67)](https://camo.githubusercontent.com/c8c27f8c1d06eb8886d5cf2027009f61cf14d5533cabe91591cbd8cb31e0fbc4/687474703a2f2f7777772e666967646963652e6f72672f696d672f6669672d3133302d31362e706e67) FigDice Templating System for PHP
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

[](#-figdice-templating-system-for-php)

[![License: MIT](https://camo.githubusercontent.com/fdf2982b9f5d7489dcf44570e714e3a15fce6253e0cc6b5aa61a075aac2ff71b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d79656c6c6f772e737667)](https://opensource.org/licenses/MIT)[![Build Status](https://github.com/figdice/figdice/actions/workflows/build.yml/badge.svg?branch=4.x)](https://github.com/figdice/figdice/actions)[![Latest Stable Version](https://camo.githubusercontent.com/370e11b2a1aaa662f901f7b62beb175642a3824ae1a25bbbdddaf236c6b0cef9/68747470733a2f2f706f7365722e707567782e6f72672f666967646963652f666967646963652f762f737461626c65)](https://packagist.org/packages/figdice/figdice)[![Coverage Status](https://camo.githubusercontent.com/da04205f9449512d0d3def35c470e8eab6ca63fdabebf8f4a29abc05b84b843d/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f666967646963652f666967646963652f62616467652e7376673f6272616e63683d342e78)](https://coveralls.io/github/figdice/figdice?branch=4.x)[![@figdice on Twitter](https://camo.githubusercontent.com/98c626cb35ff60c4bc866292bb72a686430ca7983e9bea38c420fe8fb2845d54/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f747769747465722d253430666967646963652d3531383963372e737667)](https://twitter.com/figdice)

Abstract
========

[](#abstract)

FigDice is a templating engine for PHP. It differs from most of the popular template systems, with regards to the way the presentation data are made available to the templates: instead of pushing the data from the Controller to the View, you build Views that pull the immutable data that they need.

FigDice focuses on the Web Designer stand-point. Designers and Developers agree together on structure of the self-contained *beans* (called Feeds in FigDice) that Developers make available to Designers, and then the Designers may reuse them anywhere they need, and combine them with other Feeds into pages and macros. The View Controllers in FigDice become generic presenters whcih don't need to know the details of what is presented in what template, since the templates themselves will activate their favorite Feeds to pull their data.

See **[figdice.org](https://www.figdice.org/)**

Try a [Live Demo](https://demo.figdice.org/) now!
=================================================

[](#try-a-live-demo-now)

Presentation and Tutorial:

- [SitePoint | Getting Started With FigDice](http://www.sitepoint.com/?s=figdice) (English)
- [php\[architect\] | December 2015](https://www.phparch.com/magazine/2015-2/december/) (English)
- [GNU/Linux Magazine France | 158, March 2013](http://connect.ed-diamond.com/GNU-Linux-Magazine/GLMF-158/FigDice-un-Templating-System-efficace-et-original) (French)

Features
--------

[](#features)

- **Fast, easy** and powerful Template Engine
- **HTML syntax** for your Templates: FigDice brings a set of [extended attributes](https://github.com/figdice/figdice/wiki/The-FigDice-markup) to help you construct the logics.
- You can display your templates **WYSIWYG** in your browser/editor
- Manipulate your data with the help of a simple and powerful [expression parser](https://github.com/figdice/figdice/wiki/Expression)
- Built-in [i18n](https://github.com/figdice/figdice/wiki/Internationalization), using keys/values from cached dictionaries
- Inclusions, loops, conditions, with a **non-intrusive syntax** inside the document
- No programming required, for the Template designers
- Hermetic separation between the application's layers (Presentation / Logics)
- Inversion of control: the Templates pull the data on-demand. The controllers need not know the templates by heart beforehand

Installation
============

[](#installation)

Add the figdice dependency to the `require` section of your `composer.json` file:

```
"figdice/figdice": "~3.x-dev"

```

Getting Started
===============

[](#getting-started)

Browse the [examples](https://github.com/figdice/figdice-examples)!

See [Wiki](https://github.com/figdice/figdice/wiki) for more details.

###  Health Score

42

—

FairBetter than 89% of packages

Maintenance48

Moderate activity, may be stable

Popularity26

Limited adoption so far

Community16

Small or concentrated contributor base

Maturity67

Established project with proven stability

 Bus Factor1

Top contributor holds 87.6% 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 ~214 days

Recently: every ~623 days

Total

21

Last Release

149d ago

Major Versions

2.x-dev → 3.02017-03-09

3.x-dev → 4.x-dev2026-01-31

PHP version history (3 changes)2.0.4PHP &gt;=5.3.0

2.x-devPHP &gt;=5.4

3.x-devPHP &gt;=7.1

### Community

Maintainers

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

---

Top Contributors

[![zzgab](https://avatars.githubusercontent.com/u/3754439?v=4)](https://github.com/zzgab "zzgab (218 commits)")[![figdice](https://avatars.githubusercontent.com/u/7250633?v=4)](https://github.com/figdice "figdice (29 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (1 commits)")[![jfrancr](https://avatars.githubusercontent.com/u/13480540?v=4)](https://github.com/jfrancr "jfrancr (1 commits)")

---

Tags

phptemplate-enginexmlhtmltemplatetemplatingviewspresentation

###  Code Quality

TestsPHPUnit

### Embed Badge

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

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

###  Alternatives

[phug/phug

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

66297.7k14](/packages/phug-phug)[talesoft/tale-jade

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

8819.3k5](/packages/talesoft-tale-jade)[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)

PHPackages © 2026

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