---
title: "Introduction"
manual: "Environment State Manager"
version: "main"
permalink: "https://docs.typo3.org/permalink/fgtclb/environment-state-manager:introduction@main"
source: "Introduction/Index.rst"
rendered: "2026-10-17T14:50:33+00:00"
---

# Introduction {#introduction}

## What does it do? {#what-does-it-do}

The **Environment State Manager** extension provides a programmatic
way to build, apply and restore a TYPO3 environment.

It is useful whenever code that usually runs in a frontend request context has
to be executed in a different context – for example in a backend module, a
command line task or a middleware – where a fully initialized frontend
environment (request, frontend controller, TypoScript, language and visibility
aspects) is not available.

> [!NOTE]
> Both **frontend** and **backend** environment handling are implemented.
> The API is built around an `ApplicationType`, selecting the matching
> environment builder for the requested type.

## Features {#features}

-   `EnvironmentBuilderFactory` returning a TYPO3 core version compatible
    environment builder for TYPO3 v13 and v14. A `FrontendEnvironmentBuilder`
    and a `BackendEnvironmentBuilder` are shipped.
-   `StateManager` to build, apply and restore an environment state.
-   `StateApplyEvent` and `StateBackupEvent` PSR-14 events dispatched
    around applying and backing up the state.

## Compatibility {#compatibility}

| Branch | Extension | TYPO3 | PHP |
| --- | --- | --- | --- |
| main | 2.x | v13 / v14 | 8.2 - 8.5 |
| 1 | 1.x | v12 / v13 | 8.1 - 8.5 |
