PHPackages                             starcitizentools/thumbro - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. starcitizentools/thumbro

ActiveMediawiki-extension[Utility &amp; Helpers](/categories/utility)

starcitizentools/thumbro
========================

Imrproves and expands thumbnails in MediaWiki.

v2.0.0(3w ago)11491—3.3%4GPL-2.0-or-laterPHPCI passing

Since Apr 7Pushed 2w ago2 watchersCompare

[ Source](https://github.com/StarCitizenTools/mediawiki-extensions-Thumbro)[ Packagist](https://packagist.org/packages/starcitizentools/thumbro)[ Docs](https://www.mediawiki.org/wiki/Extension:Thumbro)[ RSS](/packages/starcitizentools-thumbro/feed)WikiDiscussions main Synced today

READMEChangelog (6)Dependencies (18)Versions (20)Used By (0)

👍🖼️😎 Thumbro
=======

[](#thumbro)

> *Can we get Thumbor for the wiki?
> We have Thumbor at home.
> Thumbor at home:*

**Thumbro** improves and expands thumbnail generation in MediaWiki. Instead of relying on a single tool, it automatically picks the most suitable image library for each file format — so every thumbnail comes out at the best quality and smallest size, with no manual tuning and room to add better libraries over time. Forked from [Extension:VipsScaler](https://www.mediawiki.org/wiki/Extension:VipsScaler).

Features
--------

[](#features)

- Routes each format to the best-suited image library automatically (currently [libvips](https://www.libvips.org) and [libwebp](https://developers.google.com/speed/webp/docs/gif2webp)), instead of MediaWiki's default ImageMagick and GD
- Produces higher-quality, smaller thumbnails — including for animated images
- Renders WebP thumbnails by default for GIF, JPEG, PNG, and WebP (including animated)
- Lets you fine-tune encoding per format with custom load and save options
- Extends thumbnail support to more formats, such as animated WebP
- Adds a `` element to images via the `ThumbroBeforeProduceHtml` hook
- Adds a hidden anchor so web crawlers can reach the original-resolution image ([T54647](https://phabricator.wikimedia.org/T54647))

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

[](#installation)

1. Install the image libraries Thumbro uses. [libvips](https://www.libvips.org/install.html) is required; [libwebp](https://developers.google.com/speed/webp/docs/gif2webp) is recommended for crisp, compact animated-GIF thumbnails. On Debian-based systems:

```
apt-get install libvips-tools webp
```

2. [Download](https://github.com/StarCitizenTools/mediawiki-extensions-Thumbro/archive/main.zip) the extension and place the files in a directory called `Thumbro` in your `extensions/` folder.
3. Add the following to the bottom of your `LocalSettings.php`, **after all other extensions**:

```
wfLoadExtension( 'Thumbro' );
```

4. **✔️ Done** — visit Special:Version on your wiki to confirm the extension is installed.

Configuration
-------------

[](#configuration)

> ℹ️ **Thumbro works out of the box — no configuration required.**

### `$wgThumbroLibraries`

[](#wgthumbrolibraries)

The image libraries Thumbro can run, keyed by library. Each library maps its binaries (by binary name) to their executable paths. `libwebp` ships two tools — `gif2webp` and `cwebp` — so it owns both.

Default:

```
$wgThumbroLibraries = [
	'libvips' => [ 'vipsthumbnail' => '/usr/bin/vipsthumbnail' ], // resize (+ vips-webp encode)
	'libwebp' => [
		'gif2webp' => '/usr/bin/gif2webp', // animated-GIF encode
		'cwebp'    => '/usr/bin/cwebp',     // static-WebP encode
	],
];
```

### `$wgThumbroOptions`

[](#wgthumbrooptions)

Controls how each file type is thumbnailed as a **resize → encode** pipeline. The defaults are tuned per format, so most wikis never need to change this.

Each MIME block has:

KeyDescription`enabled`Turn Thumbro on or off for this file type`minArea` / `maxArea`Optional: only handle sources whose area (px²) is within range`resize`The resize stage: `{ "options": { … } }` — libvips load/resize options`encode`An ordered list of encoder choices. Each entry is `{ "encoder", "when"?, "options" }`. The first entry whose `when` capability guard the file satisfies is used; an entry with no `when` is the catch-all (put it last). Each encoder owns its own `options`.Encoders: `vips-webp` (libvips webpsave — also handles animation), `cwebp` (libwebp, static only — more byte-efficient), `gif2webp` (libwebp, animated). `when` guards match the file's capabilities: `animated`, `alpha` (transparency), `underThreshold` (area ≤ `$wgThumbroMaxAnimatedArea`).

Default (abridged):

```
$wgThumbroOptions = [
	// Static WebP → cwebp (smaller); animated WebP → vips; vips catch-all if cwebp is absent.
	'image/webp' => [
		'enabled' => true,
		'resize'  => [ 'options' => [] ],
		'encode'  => [
			[ 'encoder' => 'vips-webp', 'when' => [ 'animated' => true ],
			  'options' => [ 'strip' => 'true', 'Q' => '90', 'smart_subsample' => 'true' ] ],
			[ 'encoder' => 'cwebp', 'options' => [ 'q' => '80', 'm' => '6' ] ],
			[ 'encoder' => 'vips-webp',
			  'options' => [ 'strip' => 'true', 'Q' => '90', 'smart_subsample' => 'true' ] ],
		],
	],
	'image/jpeg' => [
		'enabled' => true,
		'resize'  => [ 'options' => [] ],
		'encode'  => [ [ 'encoder' => 'vips-webp',
			'options' => [ 'strip' => 'true', 'Q' => '80', 'smart_subsample' => 'false', 'effort' => '6' ] ] ],
	],
	'image/png' => [
		'enabled' => true,
		'resize'  => [ 'options' => [] ],
		'encode'  => [ [ 'encoder' => 'vips-webp',
			'options' => [ 'near_lossless' => 'true', 'Q' => '60', 'strip' => 'true' ] ] ],
	],
	// GIF: transparent animation → gif2webp; opaque animation → vips animated; else vips first-frame.
	'image/gif' => [
		'enabled' => true,
		'resize'  => [ 'options' => [] ],
		'encode'  => [
			[ 'encoder' => 'gif2webp', 'when' => [ 'animated' => true, 'alpha' => true, 'underThreshold' => true ],
			  'options' => [ 'mixed' => '', 'q' => '80', 'm' => '4' ] ],
			[ 'encoder' => 'vips-webp', 'when' => [ 'animated' => true, 'underThreshold' => true ],
			  'options' => [ 'strip' => 'true', 'Q' => '90', 'smart_subsample' => 'true' ] ],
			[ 'encoder' => 'vips-webp',
			  'options' => [ 'strip' => 'true', 'Q' => '90', 'smart_subsample' => 'true' ] ],
		],
	],
];
```

### Other options

[](#other-options)

NameDescriptionValuesDefault`$wgThumbroMaxAnimatedArea`Largest animation Thumbro will fully re-encode, measured as width × height × frames. Bigger animations are rendered as a single static frame to keep thumbnailing fast.integer`25000000``$wgThumbroEnabled`Disable Thumbro across the wiki (the Special:ThumbroTest page still works)`true` / `false``true``$wgThumbroExposeTestPage`Enable the Special:ThumbroTest comparison page`true` / `false``false``$wgThumbroTestExpiry`Cache lifetime, in seconds, for images streamed to Special:ThumbroTestinteger`3600`Comparing thumbnails
--------------------

[](#comparing-thumbnails)

Thumbro ships a special page for comparing thumbnails before and after Thumbro. Enable it with:

```
// Enable the Special:ThumbroTest page
$wgThumbroExposeTestPage = true;
```

To keep the "before" thumbnail untouched by Thumbro, either disable Thumbro site-wide:

```
// Disable Thumbro site-wide
$wgThumbroEnabled = false;
```

…or disable the specific file format you want to test under `$wgThumbroOptions`.

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

[](#requirements)

- [MediaWiki](https://www.mediawiki.org) 1.43.0 or later
- **[libvips](https://www.libvips.org)** (8.14 or later; older versions may work but are untested) — required. Drives core thumbnail generation via the `vipsthumbnail` command.
- **[libwebp](https://developers.google.com/speed/webp/docs/using)** (the `cwebp` and `gif2webp` tools; Debian/Ubuntu `webp` package) — recommended. `cwebp` encodes static WebP thumbnails more compactly than libvips; `gif2webp` encodes animated GIFs to compact animated WebP, far smaller than libvips for transparent animations. Without it, both fall back to libvips automatically.
- [Imagick](https://github.com/Imagick/imagick) — optional. Powers the detailed comparison statistics on Special:ThumbroTest.

###  Health Score

49

—

FairBetter than 94% of packages

Maintenance96

Actively maintained with recent releases

Popularity26

Limited adoption so far

Community23

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~85 days

Recently: every ~64 days

Total

6

Last Release

25d ago

Major Versions

v1.2.1 → v2.0.02026-06-07

### Community

Maintainers

![](https://www.gravatar.com/avatar/421898af9788651cc8fe6c06069092f102e093e32e6f0e6437178aa8a180d328?d=identicon)[alistair3149](/maintainers/alistair3149)

---

Top Contributors

[![translatewiki](https://avatars.githubusercontent.com/u/24829418?v=4)](https://github.com/translatewiki "translatewiki (225 commits)")[![alistair3149](https://avatars.githubusercontent.com/u/9260542?v=4)](https://github.com/alistair3149 "alistair3149 (160 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (31 commits)")[![btongminh](https://avatars.githubusercontent.com/u/3720675?v=4)](https://github.com/btongminh "btongminh (26 commits)")[![umherirrender](https://avatars.githubusercontent.com/u/1174884?v=4)](https://github.com/umherirrender "umherirrender (23 commits)")[![reedy](https://avatars.githubusercontent.com/u/67615?v=4)](https://github.com/reedy "reedy (16 commits)")[![legoktm](https://avatars.githubusercontent.com/u/81392?v=4)](https://github.com/legoktm "legoktm (12 commits)")[![jdforrester](https://avatars.githubusercontent.com/u/881572?v=4)](https://github.com/jdforrester "jdforrester (6 commits)")[![bawolff](https://avatars.githubusercontent.com/u/6529932?v=4)](https://github.com/bawolff "bawolff (4 commits)")[![siebrand](https://avatars.githubusercontent.com/u/210297?v=4)](https://github.com/siebrand "siebrand (4 commits)")[![ZoruaFox](https://avatars.githubusercontent.com/u/96456728?v=4)](https://github.com/ZoruaFox "ZoruaFox (2 commits)")[![Ammarpad](https://avatars.githubusercontent.com/u/45658045?v=4)](https://github.com/Ammarpad "Ammarpad (2 commits)")[![DannyS712](https://avatars.githubusercontent.com/u/46829944?v=4)](https://github.com/DannyS712 "DannyS712 (2 commits)")[![hashar](https://avatars.githubusercontent.com/u/281689?v=4)](https://github.com/hashar "hashar (2 commits)")[![Krinkle](https://avatars.githubusercontent.com/u/156867?v=4)](https://github.com/Krinkle "Krinkle (2 commits)")[![MaxSem](https://avatars.githubusercontent.com/u/1260606?v=4)](https://github.com/MaxSem "MaxSem (1 commits)")[![mdew192837](https://avatars.githubusercontent.com/u/6820349?v=4)](https://github.com/mdew192837 "mdew192837 (1 commits)")[![ndrewh](https://avatars.githubusercontent.com/u/2116451?v=4)](https://github.com/ndrewh "ndrewh (1 commits)")[![Pl217](https://avatars.githubusercontent.com/u/16909534?v=4)](https://github.com/Pl217 "Pl217 (1 commits)")[![prachatos](https://avatars.githubusercontent.com/u/8720115?v=4)](https://github.com/prachatos "prachatos (1 commits)")

---

Tags

mediawiki-extensionmediawikiextensionThumbro

### Embed Badge

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

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

###  Alternatives

[helsingborg-stad/municipio

A bootstrap theme for creating municipality sites.

4028.5k10](/packages/helsingborg-stad-municipio)[mediawiki/maps

Adds various mapping features to MediaWiki

84152.3k3](/packages/mediawiki-maps)[starcitizentools/citizen-skin

A beautiful, usable, responsive MediaWiki skin with in-depth extension support. Originally developed for the Star Citizen Wiki.

3376.6k](/packages/starcitizentools-citizen-skin)[mediawiki/semantic-glossary

A terminology markup extension with a Semantic MediaWiki back-end

1452.6k](/packages/mediawiki-semantic-glossary)[starcitizentools/tabber-neue

Allows to create tabs within a page. Forked from Extension:Tabber

235.4k](/packages/starcitizentools-tabber-neue)[civicrm/civicrm-drupal-8

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

19251.4k3](/packages/civicrm-civicrm-drupal-8)

PHPackages © 2026

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