
Image: the FrankenPHP logo, from dunglas.dev — the site of FrankenPHP creator Kévin Dunglas. Used here with attribution as the article illustration.
FrankenPHP 1.14 + PHP 8.6: Serve a PHP App With a Single Binary — No Nginx, No PHP-FPM
Evidence: RESEARCH_ONLY — NOT LAB TESTED. This article is based on primary sources read on 27 November 2026: the FrankenPHP 1.14.0 release notes and the official FrankenPHP documentation (docs, Docker, production, worker mode, migration, Laravel, Symfony, configuration and known-issues pages). The deployment steps below were not run in a lab, and no command output in this article comes from a live run. Nothing here describes a tested deployment, a tested configuration change, or a measured result. See Verification scope.
The question
You run a Laravel or Symfony app behind the usual pair: Nginx (or Apache) in front, PHP-FPM behind it, plus a separate setup for TLS certificates. Every deploy touches two services, two configs, and a FastCGI hop between them. FrankenPHP 1.14.0, released 22 November 2026, is a good moment to ask whether that pair can go away: it makes PHP 8.6 the default runtime and adds a one-line way to serve pre-compressed assets.
The decision up front: if you are deploying a Laravel or Symfony app and you are comfortable with Docker, serve it with the dunglas/frankenphp image (PHP 8.6 by default) behind a minimal Caddyfile — start in classic mode, add the one-line pre-compressed asset block, and only switch to worker mode once you understand what state persists between requests. FrankenPHP is a modern application server for PHP built on top of the Caddy web server, and it replaces both your web server (Nginx, Apache) and PHP-FPM with a single binary. Automatic HTTPS, HTTP/2 and HTTP/3 come with it. What follows is a field guide assembled from the official docs — not a lab report.
What changed in FrankenPHP 1.14.0
FrankenPHP 1.14.0 was released on 22 November 2026 and is the latest release as of 27 November 2026. It follows the 1.13.5 and 1.13.6 releases. PHP 8.6 itself went generally available on 19 November 2026, three days earlier. Three changes matter for this guide:
- PHP 8.6 is now the default. The Docker images tagged
latest, the static binaries and the Windows builds now ship PHP 8.6. Thelatestand version-only tags (1.14,1) point to PHP 8.6; older PHP versions remain available viaphp8.xtags, for exampledunglas/frankenphp:1.14-php8.5. If your app is not ready for PHP 8.6, that tag is the escape hatch — pin it explicitly rather than drifting onto the default. php_servergains a configurable file server. Thefile_serversubdirective now accepts a block with anyfile_serveroption exceptroot(which stays onphp_server). Pre-compressed assets become a one-liner:
Use this new one-liner. The Symfony docs page still shows an older example using aphp_server { file_server { precompressed zstd br gzip } }handleblock for the same job; the release notes say that example was fixed, but the page had not caught up at research time, so follow the release notes and the configuration docs instead.- The PHP 8.6 Docker images drop
mbstringand PECL. Like the official PHP images, the PHP 8.6 variants no longer includembstringnor PECL. Install the extensions you need withinstall-php-extensions—mbstringmust now be added explicitly if your app needs it. Some extensions have no PHP 8.6 release yet (amqp, apcu, igbinary, imagick, lz4, memcached, msgpack, redis, xlswriter, and others) and are built from their development branches or from pull requests adding support in 1.14.0. Check your extension list before you commit to PHP 8.6.
The bundled components in 1.14.0 are Caddy 2.11.9, Mercure 1.1.6 and Vulcain 1.4.6 — the 1.14.0 changelog lists no component bump over those versions, so do not assume newer ones. FrankenPHP itself is licensed under the MIT licence; the bundled Caddy is Apache 2.0 and the optional Mercure library is AGPL, so the whole stack is not MIT. FrankenPHP lives in the php GitHub organisation since June 2025, with PHP Foundation support since May 2025; it was created by Kévin Dunglas and is sponsored by Les-Tilleuls.coop.
For context on the PHP side of this release, see the November PHP releases on this site: PHP November 2026 security release.
Choose your path: Docker image or static binary
| Path | When it fits | What you get |
|---|---|---|
| Docker image (recommended) | You deploy with containers and want the full production setup in one image | dunglas/frankenphp, PHP 8.6 by default, Debian or Alpine variants |
| Static binary | A bare VM or server with no container runtime | One frankenphp binary via the install script, Homebrew, or deb/rpm/apk |
| Windows build | Windows hosts | Official PHP binary for Windows, built with Visual Studio 2026 in 1.14.0 |
Docker images exist for PHP 8.2, 8.3, 8.4, 8.5 and 8.6, in Debian (trixie/bookworm) and Alpine variants; Debian is recommended. The tag pattern is dunglas/frankenphp:<frankenphp-version>-php<php-version>-<os>, for example 1-php8.6 or 1.14-php8.5. Images are rebuilt on new releases and daily at 04:00 UTC when new official PHP images appear; the latest and 1-php8.6 tags move, while digests never change — pin by digest for reproducible deploys (see Production hardening).
Note the PHP version floor: PHP 8.2 reaches end of life on 31 December 2026, and PHP 8.1 is already end of life and gets no fixes. If you are still on either, the move to the PHP 8.6 default is also a good moment to plan that upgrade — but that is a separate migration from switching servers, and you can do it first on the php8.5 tag if needed.
The static-binary path is documented on the FrankenPHP docs index: on Linux and macOS, curl https://frankenphp.dev/install.sh | sh installs an appropriate binary, and on Windows, irm https://frankenphp.dev/install.ps1 | iex in PowerShell does the same. Prefer the Docker path above; if you use the install script, download it first, read it, then run the local file (curl -fsSL https://frankenphp.dev/install.sh -o install.sh, inspect it, then sh install.sh) instead of piping a remote script straight into a shell. Linux binaries are statically linked, macOS binaries are self-contained, and both contain most popular PHP extensions. (The docs landing page still said “binaries containing PHP 8.5” at the time of research; the release notes are authoritative for 1.14.0, so this article does not quote the landing page on that point.)
If you already run a container platform and want to compare approaches before committing to a single binary, the self-hosted PaaS route is covered in Dokploy: self-hosted PaaS on your own server and Coolify: self-hosted Docker PaaS.
Minimal working setup: Docker Compose
The official production tutorial is a short one: a Dockerfile, a compose.yaml, a DNS record, and docker compose up --wait. Start in classic mode — each request boots the app from scratch, like PHP-FPM — and treat worker mode (below) as a second step.
Dockerfile (adapted from the official production tutorial):
FROM dunglas/frankenphp:1.14@sha256:36b5ff13ee2be31da01b095c2bdcd348040aed1b638148f4ca1ca97ff1ab927b
ENV SERVER_NAME=your-domain.example.com
RUN mv "$PHP_INI_DIR/php.ini-production" "$PHP_INI_DIR/php.ini"
RUN install-php-extensions pdo_mysql gd intl zip opcache mbstring
COPY . /app/public
Never copy secrets into the image: add a .dockerignore that excludes .env (and any other file holding secrets) so COPY . /app/public cannot bake them into the image, and pass runtime secrets via Compose env_file: or environment variables instead. SERVER_NAME above is a placeholder domain, not a secret. The same applies to the docker run -v $PWD:/app one-liner below — a mounted .env is visible inside the container, so keep secrets out of the mounted directory.
Three details in that file deserve attention. First, SERVER_NAME sets the domain the server answers for. Second, mbstring is listed explicitly in the install-php-extensions line because the PHP 8.6 images no longer ship it — if your app or a dependency needs it and you omit it, the failure will surface at runtime, not at build time. Third, the base image is pinned by digest — the digest above was verified on Docker Hub on 27 November 2026, but the daily rebuilds produce a new digest, so re-check it at deploy time. SERVER_ROOT sets the web root, FRANKENPHP_CONFIG injects worker configuration, and CADDY_GLOBAL_OPTIONS injects global Caddy options.
compose.yaml (single service, from the official production tutorial):
services:
php:
build: .
user: "1000:1000"
cap_add:
- NET_BIND_SERVICE
restart: always
ports:
- "80:80"
- "443:443"
- "443:443/udp"
volumes:
- caddy_data:/data
- caddy_config:/config
volumes:
caddy_data:
caddy_config:
The service runs as UID 1000 with only the capability needed to bind ports 80/443 — adjust the UID to match the owner of your app files, and re-check the image digest at deploy time (see the Dockerfile note above).
The two volumes hold certificates and Caddy configuration — do not skip them, or certificates will be re-issued on every recreate. The 443:443/udp mapping is what HTTP/3 needs; without it, HTTP/3 silently does not happen. Then point the domain’s A record at the server and run docker compose up --wait; the HTTPS certificate is generated automatically.
HTTPS is automatic via Caddy (Let’s Encrypt by default), but a domain name is mandatory — bare IP addresses are not supported by Let’s Encrypt. For local development, FrankenPHP generates a TLS certificate for localhost by default; use https://localhost and accept the self-signed certificate, not https://127.0.0.1.
Behind a reverse proxy or load balancer, set Caddy’s trusted_proxies global option and configure the framework to trust the proxy (Symfony TRUSTED_PROXIES, Laravel trustedproxies middleware) — otherwise X-Forwarded-* headers are ignored and your app will see the proxy’s address instead of the client’s.
The Caddyfile: minimal site, then the pre-compressed one-liner
A typical Nginx virtual host becomes a three-line site block. From the official migration docs:
example.com {
root /var/www/app/public
php_server
}
php_server handles PHP routing, try_files-like behaviour and static file serving, and an existing php.ini works as-is. That is the whole migration for a simple app — no FastCGI configuration, no self-managed TLS certificates.
Now add the 1.14.0 feature: pre-compressed assets in one block.
example.com {
root /var/www/app/public
php_server {
file_server {
precompressed zstd br gzip
}
}
}
This serves a pre-compressed .zst, .br or .gz file next to an asset when the client supports it, instead of compressing on the fly for every request. It only works if the compressed files actually exist next to the assets at deploy time. On Symfony, AssetMapper pre-compresses assets with Brotli and Zstandard at deploy time — run php bin/console asset-map:compile — and the file_server directive serves them directly. Keep encode zstd br gzip for on-the-fly compression of the rest of the responses that have no pre-compressed file. If you generate assets with a build step (Vite, Webpack, or similar), that step needs to emit the .zst/.br/.gz variants, or the directive will simply fall through to the uncompressed file.
Framework wiring: Laravel Octane and Symfony
Laravel
For a quick local run, the Laravel docs give a one-liner from the app directory:
docker run -p 80:80 -p 443:443 -p 443:443/udp -v $PWD:/app dunglas/frankenphp
With the standalone binary, the Caddyfile uses root public/, an optional encode zstd br gzip line, and php_server { try_files {path} index.php }, then frankenphp run.
Worker mode for Laravel goes through Octane:
composer require laravel/octane
php artisan octane:install --server=frankenphp
php artisan octane:frankenphp
Useful options on octane:frankenphp: --host (default 127.0.0.1), --port (default 8000), --admin-port (2019), --workers (auto by default), --max-requests (default 500), --caddyfile, --https (enables HTTPS, HTTP/2 and HTTP/3 with automatic certificates), --http-redirect, --watch, and --log-level. Laravel apps can also be packaged as standalone binaries with a static-build Dockerfile (EMBED=dist/app/ ./build-static.sh); set LARAVEL_STORAGE_PATH for embedded apps.
Symfony
The recommended path is Symfony Docker — the official setup by FrankenPHP’s author — which ships FrankenPHP with automatic HTTPS, HTTP/2, HTTP/3 and worker mode out of the box. Standalone, the Caddyfile is root public/ plus php_server { worker ./public/index.php }, then frankenphp run.
Since Symfony 7.4, FrankenPHP worker mode is natively supported. On older versions, install composer require runtime/frankenphp-symfony and set APP_RUNTIME=Runtime\FrankenPhpSymfony\Runtime. Symfony’s AssetMapper pairing with the new pre-compressed one-liner is covered in The Caddyfile above.
Worker mode — and the state that persists between requests
Worker mode boots the app once and keeps it in memory; FrankenPHP then handles incoming requests in a few milliseconds (the docs’ wording, not a measured claim — no benchmark was run for this article). Enable it with FRANKENPHP_CONFIG="worker /app/path/to/your/worker/script.php" in Docker, frankenphp php-server --worker /path/to/your/worker/script.php, or in a Caddyfile with php_server { worker index.php 4 } or the global frankenphp { worker { file … num … } } block.
The defaults: 2 workers per CPU. Worker threads come on top of num_threads (the threads left for requests no worker serves); max_threads limits the whole process, workers included. The default num_threads is what is left of 2× CPUs once workers have their threads, with a minimum of 1.
Restart workers with --watch on file changes, or with curl -X POST http://localhost:2019/frankenphp/workers/restart via the Caddy admin API. A worker that crashes with a non-zero exit code restarts with exponential backoff, and fails with too many consecutive failures if it keeps failing (configurable via max_consecutive_failures, default 6). For memory-leak mitigation, the MAX_REQUESTS environment variable or the max_requests global option (experimental) restarts a thread after N requests.
This is the part to read before enabling worker mode. Only request-tied state is reset between requests: superglobals (except $_ENV), the request body, response headers and output, the session, and the URL rewriter. Everything else persists on the same worker thread:
| What persists across requests | What to do about it |
|---|---|
$_ENV modifications and putenv() writes | Never store request-specific or sensitive data there; read config once at boot |
| Static variables, class statics, globals | Reset them explicitly, or keep request state out of them |
| In-memory caches | Treat as shared across requests, not per-request |
ini_set(), chdir(), error-handler changes | Restore them, or set them once at boot and leave them alone |
error_get_last(), libxml errors, strtok() state, http_get_last_response_headers() | Clear with error_clear_last(), libxml_clear_errors(), http_clear_last_response_headers() (PHP 8.4+) |
Seeded PRNG sequences (mt_srand/srand → mt_rand, rand, shuffle, str_shuffle, array_rand) | Reseed with mt_srand() per request; prefer Random\Randomizer with its own engine |
| Objects in reference cycles | Call gc_collect_cycles() after frankenphp_handle_request(); their destructors can otherwise run during a later request |
Shutdown functions, umask(), setlocale() | Shutdown functions run when the worker stops, not at end of request; umask()/setlocale() affect the whole process |
Frameworks handle most of this for you: Symfony services holding request state should implement ResetInterface, and Laravel Octane resets state for you. Even so, start in classic mode and switch to worker mode second — worker mode is a performance step, not a drop-in replacement for PHP-FPM, and state leaks are real. The docs’ own framing is the same: classic mode is the safe starting point for migration.
Migrating from Nginx + PHP-FPM
The official migration docs map each piece of the old stack to the new one:
| Nginx + PHP-FPM | FrankenPHP |
|---|---|
| Nginx/Apache + PHP-FPM | Single frankenphp binary |
php-fpm.conf pool | frankenphp global option |
Nginx server {} | Caddyfile site block |
php_value / php_admin_value | php_ini directive |
pm = static / pm.max_children | num_threads |
pm = dynamic | max_threads auto |
| Web-server request filtering | Caddy routes and matchers |
After migrating you no longer need Nginx or Apache, PHP-FPM, FastCGI configuration, or self-managed TLS certificates. Three behaviour changes need attention:
max_execution_timeis now wall time. In FrankenPHP it counts wall time, while non-ZTS PHP-FPM on Linux counts CPU time. Waiting on a database query, an HTTP call,sleep(), or a session-file lock now counts toward the limit — so a value tuned for PHP-FPM can be too low. Re-tune it for the new meaning instead of copying the old number.- Request filtering must be re-added as Caddy matchers. Anything Nginx used to reject (for example, a
TRACErequest) needs an explicit Caddy route returning the right status, such as 405. It does not carry over automatically. - Trust the proxy explicitly if there is one in front — see the
trusted_proxiesnote in Minimal working setup.
Production hardening
- Pin the image by digest. Tags move on daily rebuilds; digests never change. Binaries of the latest release are rebuilt daily (midnight UTC for Linux/macOS, 08:00 UTC for Windows) to include PHP security fixes. Verify a binary with
frankenphp versionand GitHub artifact attestation (gh attestation verify ... --repo php/frankenphp); for byte-for-byte reproducibility, store a verified copy or pin Docker images by digest. - Run under a supervisor. Since PHP 8.2.35/8.3.36/8.4.27/8.5.12, exceeding
memory_limitraises the fatal error at the next function call or loop iteration, and a single huge allocation can exit the process. PHP-FPM loses one child; FrankenPHP serves all requests from threads of a single process, so every in-flight request is lost and the server stops until restarted. Docker’srestart: alwaysin the Compose file above — or systemdRestart=for the binary — is not optional decoration. - Run non-root where you can. Non-root operation is supported; binding ports 80/443 needs the
CAP_NET_BIND_SERVICEcapability, while unprivileged ports (1024 and above) need no capability at all. - Install extensions explicitly.
mbstringand PECL are gone from the PHP 8.6 images; add what you need withinstall-php-extensionsand verify the extension list (see Limitations) before you deploy. - Custom Caddy modules go through
xcaddy(builder image). Distroless or Docker-hardened base images are possible but shell-less, which makes debugging harder — production-only, in the docs’ framing.
For the container-runtime side of a home server, the lighter-weight alternative to Docker Desktop is covered in Kiri: a Rust container runtime replacing Docker Desktop, and the single-binary gateway pattern has a parallel in the AI space in LiteLLM: a multi-model gateway with an OpenAI-compatible API.
Limitations: what to check before you commit
- Extensions on PHP 8.6. Several extensions (amqp, apcu, igbinary, imagick, lz4, memcached, msgpack, redis, xlswriter, and others) have no PHP 8.6 release yet and are built from development branches or pull requests in 1.14.0. If your app depends on one of them, verify its PHP 8.6 status first — or stay on the
1.14-php8.5tag until it lands. - Incompatible extensions.
imap,newrelicandpcovare incompatible because they are not thread-safe (use javanile/php-imap2, webklex/php-imap or ImapEngine for IMAP; collectpcovcoverage via the CLI SAPI instead).imagickhas an OpenMP conflict: ImageMagick threads conflict with FrankenPHP threads and can cause instability or crashes — mitigate withImagick::setResourceLimit(RESOURCETYPE_THREAD, 1)or by compiling ImageMagick with--disable-openmp. OpenMP is already disabled in static binaries and apt/apk/rpm packages; Docker images and Homebrew are affected. - Observability tooling is uneven. Datadog profiling is unstable (tracked by Datadog), and Blackfire support is beta, not feature-complete.
- Single-process memory risk. See Production hardening: a memory-limit overrun can take down the whole process and every in-flight request with it. Keep the restart policy.
- musl quirks. Static binaries and Alpine images use musl libc:
GLOB_BRACEis unavailable — prefer the GNU static binary or Debian images if that bites. Static binaries also bundle no TLS CA certificates: point OpenSSL at local CA certs (SSL_CERT_FILE/SSL_CERT_DIR) or installca-certificates, or STARTTLS and similar will fail. - Composer inside the image. Composer scripts calling a
phpbinary fail inside FrankenPHP images (Composer does not know the binary, and the-dflag is unsupported). The workaround is a/usr/local/bin/phpshim callingfrankenphp php-cli, plus thePHP_BINARYenvironment variable. - No performance claim in this article. No benchmark was run, and this article makes no throughput or latency claim for FrankenPHP against PHP-FPM. Treat any such figure you see elsewhere as unverified unless it comes with a reproducible method.
Verify it yourself
These are checks you can run against your own deployment, from the docs — they are reader verification steps, not lab results from this article:
frankenphp version
curl -I https://your-domain.example.com
curl -I -H "Accept-Encoding: br" https://your-domain.example.com/assets/app.css
docker compose ps
What to look for: frankenphp version reports 1.14.0; the HTTPS response carries the expected headers; a request for a pre-compressed asset with Accept-Encoding: br returns the Brotli variant (check Content-Encoding); and the Compose service stays up under restart: always. If the pre-compressed variant is not served, the .br file is missing next to the asset — regenerate it with your asset step (asset-map:compile on Symfony) and re-check.
The decision, restated
Serve the app with one binary: the dunglas/frankenphp image on PHP 8.6, a minimal Caddyfile, the one-line file_server { precompressed zstd br gzip } block, and restart: always. Start in classic mode. Add worker mode — Laravel Octane or Symfony’s native support since 7.4 — only after you have read the state-persistence table above and confirmed your app resets what it must. Pin the image by digest, install mbstring and any other extensions explicitly, and re-tune max_execution_time for wall time. If an extension your app needs has no PHP 8.6 release yet, stay on 1.14-php8.5 and revisit — the tag exists for exactly that case.
Sources
- FrankenPHP 1.14.0 release notes — github.com/php/frankenphp/releases/tag/v1.14.0 (release date 22 November 2026 corroborated by two independent secondary mirrors; the GitHub page text extract did not render the date — see Verification scope)
- FrankenPHP releases — github.com/php/frankenphp/releases
- FrankenPHP docs — frankenphp.dev/docs/
- Worker mode — frankenphp.dev/docs/worker/
- Migrating from Nginx/PHP-FPM — frankenphp.dev/docs/migrate/
- Docker images — frankenphp.dev/docs/docker/
- Deploy in production — frankenphp.dev/docs/production/
- Laravel integration — frankenphp.dev/docs/laravel/
- Symfony integration — frankenphp.dev/docs/symfony/
- Known issues — frankenphp.dev/docs/known-issues/
- Configuration — frankenphp.dev/docs/config/
- PHP November 2026 security release (PHP 8.6 GA, 19 November 2026) — chainguard.dev
Verification scope
- All facts verified 27 November 2026 against the sources above; the research ledger records 26 verified claims and 4 unverified items.
- The 1.14.0 release date (22 November 2026) is corroborated by two independent secondary mirrors (a Darkwood release mirror and a Darkwood Facebook post dated 22 November 2026) and by release ordering after the 19 November releases; the GitHub releases page text extract did not render the publication date.
- The exact PHP 8.6 patch version inside 1.14.0 is not stated anywhere in this article — the release notes say “PHP 8.6” only, and no patch version is claimed.
- No performance or throughput figure for FrankenPHP versus PHP-FPM appears in this article — no benchmark was run and no such claim was verified.
- The exact CPU architecture list for the 1.14.0 Docker images is not claimed — the docs say “popular architectures” only.
- Whether the docs landing page (which still said “binaries containing PHP 8.5” at crawl time on 26 November 2026) has since been updated is not verified; the release notes were trusted over the landing page.
- The MIT licence for FrankenPHP is confirmed via GitHub repo metadata as reported by multiple independent sources; the LICENSE file text itself was not read directly in this session.
- The Symfony docs page still showed the older
handle-block pre-compressed example at research time; this article uses the new one-liner from the 1.14.0 release notes and the configuration docs. - The deployment, worker-mode and verification steps in this article were not run in a lab. They are documented steps from the official docs, reproduced for the reader to run.
Bình luận
Bình luận được duyệt trước khi hiển thị.Đang tải bình luận…
Để lại bình luận