PHPackages                             cpsit/typo3-config-loader - 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. cpsit/typo3-config-loader

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

cpsit/typo3-config-loader
=========================

A loader for various TYPO3-related configuration, including system configuration and configuration for third-party extensions.

2.0.0(1mo ago)613.0k↓40.1%1[1 issues](https://github.com/CPS-IT/typo3-config-loader/issues)GPL-2.0-or-laterPHPPHP ~8.2.0 || ~8.3.0 || ~8.4.0 || ~8.5.0CI passing

Since Apr 24Pushed 5d ago6 watchersCompare

[ Source](https://github.com/CPS-IT/typo3-config-loader)[ Packagist](https://packagist.org/packages/cpsit/typo3-config-loader)[ RSS](/packages/cpsit-typo3-config-loader/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (10)Dependencies (28)Versions (18)Used By (0)

TYPO3 config loader
===================

[](#typo3-config-loader)

[![Coverage](https://camo.githubusercontent.com/15bd793f0fba8edb524d4620f58542d8e982001222bcb6d87a19e3edf3ece674/68747470733a2f2f696d672e736869656c64732e696f2f636f766572616c6c73436f7665726167652f6769746875622f4350532d49542f7479706f332d636f6e6669672d6c6f616465723f6c6f676f3d636f766572616c6c73)](https://coveralls.io/github/CPS-IT/typo3-config-loader)[![CGL](https://camo.githubusercontent.com/19eea8325654a8317c11d14d339243d349a63301a1efbe7f340f690c1fb0d754/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f4350532d49542f7479706f332d636f6e6669672d6c6f616465722f63676c2e79616d6c3f6c6162656c3d63676c266c6f676f3d676974687562)](https://github.com/CPS-IT/typo3-config-loader/actions/workflows/cgl.yaml)[![Tests](https://camo.githubusercontent.com/489c08f948bd0e8ea6f37fbd9b46c084ab3e431fc60e4ffee57bee5d78bfb6d6/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f4350532d49542f7479706f332d636f6e6669672d6c6f616465722f74657374732e79616d6c3f6c6162656c3d7465737473266c6f676f3d676974687562)](https://github.com/CPS-IT/typo3-config-loader/actions/workflows/tests.yaml)[![TYPO3 support](https://camo.githubusercontent.com/bac51ba961d68cc02cd9b959e381d5326ce70af9c9ec6609626776366023b93c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5459504f332d31335f2532365f31342d6f72616e67653f6c6f676f3d7479706f33)](https://get.typo3.org/)

📦 [Packagist](https://packagist.org/packages/cpsit/typo3-config-loader) | 💾 [Repository](https://github.com/CPS-IT/typo3-config-loader) | 🐛 [Issue tracker](https://github.com/CPS-IT/typo3-config-loader/issues)

A loader for various TYPO3-related configuration, including system configuration and configuration for third-party extensions. Based on the [`helhum/config-loader`](https://github.com/helhum/config-loader)library.

🚀 Features
----------

[](#-features)

- Config loader for [system configuration](src/Loader/SystemConfigurationLoader.php)
- Config loader for [EXT:solr](src/Loader/SolrConfigurationLoader.php)
- Compatible with TYPO3 13.4 LTS and 14.3 LTS

🔥 Installation
--------------

[](#-installation)

[![Packagist](https://camo.githubusercontent.com/911a435bf03be3738304b4792769daa82bd3f3372ed17da13cf4f503895d6df1/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f63707369742f7479706f332d636f6e6669672d6c6f616465723f6c6162656c3d76657273696f6e266c6f676f3d7061636b6167697374)](https://packagist.org/packages/cpsit/typo3-config-loader)[![Packagist Downloads](https://camo.githubusercontent.com/f649b0af966b314a30fe7290a092f4d66827bab4bbcc36288ad4488c89eb592b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f63707369742f7479706f332d636f6e6669672d6c6f616465723f636f6c6f723d627269676874677265656e)](https://packagist.org/packages/cpsit/typo3-config-loader)

```
composer require cpsit/typo3-config-loader
```

⚡ Usage
-------

[](#-usage)

Tip

Read more about loader-specific configuration in the appropriate class documentation.

### Basic (non-cached)

[](#basic-non-cached)

Add the following code snippet to your project's `config/system/additional.php` file:

```
$systemConfigLoader = new CPSIT\Typo3ConfigLoader\Loader\SystemConfigurationLoader();
$systemConfigLoader->load();
```

In case your project uses EXT:solr, you can load its configuration as well:

```
$solrConfigLoader = new CPSIT\Typo3ConfigLoader\Loader\SolrConfigurationLoader();
$solrConfigLoader->load();
```

### Cached

[](#cached)

You can also use a cached version of the appropriate loaders:

```
$systemConfigLoader = new CPSIT\Typo3ConfigLoader\Loader\SystemConfigurationLoader();
$systemConfigLoader->loadCached();
```

🔍 System configuration readers
------------------------------

[](#-system-configuration-readers)

### 1. Context specific reader

[](#1-context-specific-reader)

The [`Helhum\ConfigLoader\Reader\PhpFileReader`](https://github.com/helhum/config-loader/blob/main/src/Reader/PhpFileReader.php) receives lowest priority when loading system configuration. It resolves system configuration from a context-specific file path within the `app/config/environment` directory. The default directory path can be overwritten with an environment variable `CONTEXT_CONFIGURATION_PATH`. Each file must return an array with additional system configuration values.

#### Example (default path)

[](#example-default-path)

- TYPO3 context: `Development/Local`
- File path: `app/config/environment/Development/Local.php`

**File contents:**

```
# /var/www/html/app/config/environment/Development/Local.php

return [
    'SYS' => [
        'debug' => 1,
    ],
];
```

#### Example (custom path)

[](#example-custom-path)

- TYPO3 context: `Development/Local`
- Environment variable: `CONTEXT_CONFIGURATION_PATH=config/by-context`
- File path: `config/by-context/Development/Local.php`

**File contents:**

```
# /var/www/html/config/by-context/Development/Local.php

return [
    'SYS' => [
        'debug' => 1,
    ],
];
```

### 2. Environment file reader

[](#2-environment-file-reader)

The next reader in the priority chain for system configuration is the [`Helhum\ConfigLoader\Reader\YamlFileReader`](https://github.com/helhum/config-loader/blob/main/src/Reader/YamlFileReader.php). It reads additional configuration from a configured YAML file. The file path must be specified as environment variable `ENV_FILE_PATH`. If the variable is not present, this reader is skipped.

#### Example

[](#example)

- Environment variable: `ENV_FILE_PATH=/var/www/html/env.yml`
- File path: `/var/www/html/env.yml`

**File:**

```
# /var/www/html/env.yml

SYS:
  debug: 1
```

### 3. Environment variables reader

[](#3-environment-variables-reader)

The [`Helhum\ConfigLoader\Reader\EnvironmentReader`](https://github.com/helhum/config-loader/blob/main/src/Reader/EnvironmentReader.php) receives highest priority. It is used to map environment variables to configuration values. Environment variables must be prefixed by `TYPO3` and each configuration key must be separated by `__`(two underscore characters).

#### Example

[](#example-1)

- Environment variable: `TYPO3__MAIL__transport_smtp_server`
- Configuration path: `$GLOBALS['TYPO3_CONF_VARS']['MAIL']['transport_smtp_server']`

💡 Custom loaders
----------------

[](#-custom-loaders)

In case this library does not fulfill all your requirements, you are free to extend it by your needs. A [`ConfigurationLoader`](src/Loader/ConfigurationLoader.php)interface exists which can be used to provide additional loaders. Additionally, you are free to make use of the [`EnvironmentCreator`](src/EnvironmentCreator.php) trait which allows the transformation of loaded configuration to environment variables.

Next to the `ConfigurationLoader` there exists an extended interface that is able to cache and load cached data. Use [`CacheableConfigurationLoader`](src/Loader/CacheableConfigurationLoader.php) and implement the additional method `loadCached` to make use of cached configuration.

Consider contributing to this project if you feel like some functionality is missing or not yet fully covered.

🚧 Migration
-----------

[](#-migration)

### 0.4.x/0.5.x → 1.x

[](#04x05x--1x)

- **Removal of environment variables reader compatibility layer**
    - Default key separator was changed from `_` (one underscore) to `__` (two underscores).
    - Support for feature flag environment variable `TYPO3_CONFIG_LOADER_USE_SAFE_SEPARATOR`was removed.
    - Make sure to convert existing environment variables to make use of the changed key separator, e.g. `TYPO3_SYS_debug` → `TYPO3__SYS__debug`.
- **Renaming of shipped configuration loader class names**
    - Both shipped configuration loaders were renamed from `` to `ConfigurationLoader`, e.g. [`System`](https://github.com/CPS-IT/typo3-config-loader/blob/5e516082108bce67adcf4b5b20e344725a3764f5/src/Loader/System.php) → [`SystemConfigurationLoader`](src/Loader/SystemConfigurationLoader.php).
    - Change references to the renamed classes and make sure to adapt the class names as described.
- **Hardening of configuration loader classes**
    - Both shipped configuration loaders are now marked as `final readonly`.
    - Custom configuration loaders may no longer extended default configuration loaders.
    - Change your custom implementations to a direct implementation of the [`ConfigurationLoader`](src/Loader/ConfigurationLoader.php) or [`CacheableConfigurationLoader`](src/Loader/CacheableConfigurationLoader.php) interfaces.

🧑‍💻 Contributing
----------------

[](#‍-contributing)

Please have a look at [`CONTRIBUTING.md`](CONTRIBUTING.md).

⭐ License
---------

[](#-license)

This project is licensed under [GNU General Public License 2.0 (or later)](LICENSE).

###  Health Score

54

—

FairBetter than 96% of packages

Maintenance92

Actively maintained with recent releases

Popularity32

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity64

Established project with proven stability

 Bus Factor1

Top contributor holds 54% 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 ~38 days

Recently: every ~20 days

Total

11

Last Release

52d ago

Major Versions

0.4.x-dev → 1.2.02025-11-26

1.6.0 → 2.0.02026-05-13

PHP version history (3 changes)1.0.0PHP ~8.2.0 || ~8.3.0 || ~8.4.0

0.4.1PHP ~7.4.0 || ~8.0.0 || ~8.1.0 || ~8.2.0 || ~8.3.0 || ~8.4.0

1.2.0PHP ~8.2.0 || ~8.3.0 || ~8.4.0 || ~8.5.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/16313625?v=4)[Elias Häußler](/maintainers/eliashaeussler)[@eliashaeussler](https://github.com/eliashaeussler)

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

---

Top Contributors

[![renovate[bot]](https://avatars.githubusercontent.com/in/2740?v=4)](https://github.com/renovate[bot] "renovate[bot] (75 commits)")[![eliashaeussler](https://avatars.githubusercontent.com/u/16313625?v=4)](https://github.com/eliashaeussler "eliashaeussler (61 commits)")[![konradmichalik](https://avatars.githubusercontent.com/u/4558190?v=4)](https://github.com/konradmichalik "konradmichalik (3 commits)")

---

Tags

configconfig-loadertypo3

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan, Rector

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/cpsit-typo3-config-loader/health.svg)

```
[![Health](https://phpackages.com/badges/cpsit-typo3-config-loader/health.svg)](https://phpackages.com/packages/cpsit-typo3-config-loader)
```

###  Alternatives

[friendsoftypo3/content-blocks

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

103519.9k53](/packages/friendsoftypo3-content-blocks)[wazum/sluggi

TYPO3 extension for URL slug management with inline editing, auto-sync, locking, access control, and redirects

40529.5k](/packages/wazum-sluggi)[typo3/cms-lowlevel

TYPO3 CMS Lowlevel - Technical analysis of the system. This includes raw database search, checking relations, counting pages and records etc.

178.2M317](/packages/typo3-cms-lowlevel)[typo3/cms-redirects

TYPO3 CMS Redirects - Create manual redirects, list existing redirects and automatically createredirects on slug changes.

167.4M80](/packages/typo3-cms-redirects)[typo3/cms-form

TYPO3 CMS Form - Flexible TYPO3 frontend form framework that comes with a backend editor interface.

147.6M266](/packages/typo3-cms-form)[derhansen/sf_event_mgt

Event management and registration - Configurable event management and registration extension based on ExtBase and Fluid

66338.4k10](/packages/derhansen-sf-event-mgt)

PHPackages © 2026

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