PHPackages                             sitegeist/image-jack - 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. [Image &amp; Media](/categories/media)
4. /
5. sitegeist/image-jack

ActiveTypo3-cms-extension[Image &amp; Media](/categories/media)

sitegeist/image-jack
====================

Jack of all trades concerning image optimization. Also introduces the usage of next-gen-image-formats

0.11.2(5mo ago)1181.7k↓55.8%5[6 issues](https://github.com/sitegeist/image-jack/issues)[2 PRs](https://github.com/sitegeist/image-jack/pulls)GPL-2.0-or-laterPHPPHP &gt;=8.2.0

Since Nov 4Pushed 5mo ago4 watchersCompare

[ Source](https://github.com/sitegeist/image-jack)[ Packagist](https://packagist.org/packages/sitegeist/image-jack)[ Docs](https://github.com/sitegeist/image-jack)[ RSS](/packages/sitegeist-image-jack/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (10)Dependencies (7)Versions (14)Used By (0)

Image Jack
==========

[](#image-jack)

Jack of all trades concerning image optimization. Also introduces the usage of next-gen-image-formats.

What does it do?
----------------

[](#what-does-it-do)

Adds the possibility to optimize existing jpg, gif and png files during processing. Furthermore, it can add a webP copy of every processed image.

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

[](#installation)

Use composer to add the extension:

```
composer require "sitegeist/image-jack"

```

- Completely clear all processed images via the maintenance module
- Flush Caches
- Change the server configuration (see below) or activate the fallback driver xclass

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

[](#configuration)

### Webserver

[](#webserver)

To deliver the webP images, the webserver needs to be configured properly. Example for Apache (.htaccess):

```
RewriteCond %{HTTP_ACCEPT} image/webp
RewriteCond %{REQUEST_FILENAME} (.*)\.(png|gif|jpe?g)$
RewriteCond %{REQUEST_FILENAME}\.webp -f
RewriteRule ^ %{REQUEST_FILENAME}\.webp [L,T=image/webp]

        Header append Vary Accept

```

As we are creating the webP images as copies (keeping the original image untouched) this configuration delivers the webP image if the client supports it. Otherwise, the original image is served.

#### Storage API (beta)

[](#storage-api-beta)

As a fallback solution (e.g. for remote storages) there is an option in the extension settings to activate a xclass for the storage driver. There needs to be a class for every storage driver that should be extended. The LocalDriver and the AmazonS3Driver are already available. To avoid the cache problem (first client defines the served image format) the image formats from the clients accept header are added to the page cache identifier. If this option is activated the htaccess modification (see [Webserver](#webserver)) is no longer necessary.

### Scheduler / Cronjob

[](#scheduler--cronjob)

To start the image processing a command is available:

```
jack:process --limit=20

```

The images are processed one by one. By changing the limit, the number of images to process in one run can be defined.

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

[](#requirements)

### webp

[](#webp)

For the webp conversion an installed version of Imagemagick or GraphicsMagick with webp support is required.

You can check this with:

```
gm -version | grep -i webp

```

or:

```
convert -version | grep -i webp

```

When using gd, webP support is needed.

### jpg optimization

[](#jpg-optimization)

For optimizing jpg files the binary "jpegoptim" is required. You can check this with:

```
which jpegoptim

```

(Should return a path)

If missing it can be installed for example with this command:

```
apt install jpegoptim

```

### png/gif optimization

[](#pnggif-optimization)

For optimizing png and gif files the binary "optipng" is required. You can check this with:

```
which optipng

```

(Should return a path)

If missing it can be installed for example with this command:

```
apt install optipng

```

Extension settings
------------------

[](#extension-settings)

### General

[](#general)

#### useLiveProcessing

[](#useliveprocessing)

If enabled the images are processed live on request using a LocalImageProcessor. This can lead to high load and very long loading times upon first request (depending on the number of images on the page). It is recommended to stick with the default and use the available command for processing.

#### useFallbackDriver (beta)

[](#usefallbackdriver-beta)

When enabled a xclass is used to extend the getPublicUrl function from the LocalDriver and AmazonS3Driver. This can be used if the htaccess solution is not working, e.g. for remote storages. See [Storage API (beta)](#storage-api-beta) for more details.

### WebP

[](#webp-1)

#### active

[](#active)

(De)activate the conversion.

#### converter

[](#converter)

Which way should be used to convert the images: Imagemagick/GraphicsMagick, GD or an external binary

#### options

[](#options)

Depending on the conversion type this field can be used for different purposes:

- IM/GM: Add options that are directly passed to the binary
- GD: Quality for the new images (1 - 100)
- External: The complete path to the binary to be used. You can use %s for source and target image.

### Avif

[](#avif)

#### active

[](#active-1)

(De)activate the conversion.

#### converter

[](#converter-1)

Which way should be used to convert the images: Imagemagick/GraphicsMagick, GD or an external binary

#### options

[](#options-1)

Depending on the conversion type this field can be used for different purposes:

- IM/GM: Add options that are directly passed to the binary
- GD: Quality for the new images (1 - 100)
- External: The complete path to the binary to be used. You can use %s for source and target image.

### Jpeg

[](#jpeg)

#### active

[](#active-2)

(De)activate the optimization.

#### path

[](#path)

The path to the jpegoptim binary. Please use the complete path as `is_executable` won't work correctly otherwise.

### Png

[](#png)

#### active

[](#active-3)

(De)activate the optimization.

#### path

[](#path-1)

The path to the optipng binary. Please use the complete path as `is_executable` won't work correctly otherwise.

### Logging

[](#logging)

Just activate the levels that should be written to the log file.

Custom optimizer/converter templates
------------------------------------

[](#custom-optimizerconverter-templates)

The custom template should extend AbstractTemplate and implement TemplateInterface. Just use one of the existing templates as a starting point.

Custom templates can be registered like this:

```
$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['image_jack']['templates']['myCustomTemplate'] = \Vendor\Extension\Templates\CustomTemplate::class;

```

Jack will automatically pick up and run the new template if it is available for the given image type.

Troubleshooting
---------------

[](#troubleshooting)

A log is written to var/log/typo3\_image\_jack\_\*.log

The extension settings offer the possibility to decide how verbose the logging should be.

Special thanks
--------------

[](#special-thanks)

This extension was inspired by the [webp](https://github.com/plan2net/webp) extension from plan2net.

Authors &amp; Sponsors
----------------------

[](#authors--sponsors)

- [Thorsten Schramm](https://github.com/t-schramm)
- [Benjamin Tammling](https://github.com/Atomschinken)
- [All contributors](https://github.com/sitegeist/image-jack/graphs/contributors)

*The development and the public-releases of this package is generously sponsored by our employer .*

###  Health Score

47

—

FairBetter than 93% of packages

Maintenance62

Regular maintenance activity

Popularity40

Moderate usage in the ecosystem

Community19

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 80.2% 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 ~148 days

Recently: every ~214 days

Total

9

Last Release

150d ago

PHP version history (3 changes)0.9.0PHP &gt;=7.4.0

0.11.0PHP &gt;=8.1.0

0.11.2PHP &gt;=8.2.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/3417112414b1e0e135fb48a511e90178dbf2275af7dc6178250b7123eff0a026?d=identicon)[Ulrich Mathes](/maintainers/Ulrich%20Mathes)

![](https://avatars.githubusercontent.com/u/3041069?v=4)[Benjamin Tammling](/maintainers/Atomschinken)[@Atomschinken](https://github.com/Atomschinken)

![](https://www.gravatar.com/avatar/326c29c609fdf2ccb829f66f28711ad14d48a9a28b2cb5f4901cbcd9c51ec799?d=identicon)[t-schramm](/maintainers/t-schramm)

---

Top Contributors

[![Atomschinken](https://avatars.githubusercontent.com/u/3041069?v=4)](https://github.com/Atomschinken "Atomschinken (69 commits)")[![ulrichmathes](https://avatars.githubusercontent.com/u/26324456?v=4)](https://github.com/ulrichmathes "ulrichmathes (8 commits)")[![t-schramm](https://avatars.githubusercontent.com/u/61553607?v=4)](https://github.com/t-schramm "t-schramm (7 commits)")[![avogt1701](https://avatars.githubusercontent.com/u/58982287?v=4)](https://github.com/avogt1701 "avogt1701 (1 commits)")[![s2b](https://avatars.githubusercontent.com/u/458524?v=4)](https://github.com/s2b "s2b (1 commits)")

---

Tags

imageoptimizationtypo3typo3-extension

###  Code Quality

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/sitegeist-image-jack/health.svg)

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

###  Alternatives

[friendsoftypo3/content-blocks

TYPO3 CMS Content Blocks - Content Types API | Define reusable components via YAML

103519.9k53](/packages/friendsoftypo3-content-blocks)[netresearch/rte-ckeditor-image

Image support in CKEditor for the TYPO3 ecosystem - by Netresearch

611.1M8](/packages/netresearch-rte-ckeditor-image)[pagemachine/typo3-formlog

Form log for TYPO3

23238.6k8](/packages/pagemachine-typo3-formlog)[brotkrueml/schema

Embedding schema.org vocabulary - API and view helpers for schema.org markup

34653.7k16](/packages/brotkrueml-schema)[webcoast/deferred-image-processing

Handles image processing on request instead of during page generation

1342.6k](/packages/webcoast-deferred-image-processing)[b13/assetcollector

Asset collector - Add CSS and SVG files and strings as inline style tag/inline svg to the html code.

10125.6k](/packages/b13-assetcollector)

PHPackages © 2026

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