Running Drupal with FrankenPHP: What You Need to Know

The PHP ecosystem is evolving rapidly, particularly in the area of execution and performance.
New approaches are emerging to simplify deployment and accelerate response times for applications.

Among them, FrankenPHP stands out with a model different from the classic architectures based on PHP-FPM + Nginx/Apache.

The question arises: can you run Drupal with FrankenPHP, and when does it make sense?


How Drupal Works Today

In a classic architecture, Drupal relies on:

  • A web server (Nginx or Apache)
  • PHP-FPM to execute PHP code
  • A database (MySQL, MariaDB, PostgreSQL…)
  • Optionally a caching system (Redis, Memcached, CDN…)

This model, solid and proven, nonetheless presents:

  • Multiple infrastructure layers
  • Complex configuration
  • Non-negligible maintenance costs

What is FrankenPHP?

FrankenPHP is a modern application server for PHP, built around:

  • Caddy, a fast and modern HTTP server
  • Direct PHP code execution (without PHP-FPM)
  • A persistent (worker) mode inspired by solutions like Node.js or Swoole

Goal

Simplify the architecture and improve performance by reducing intermediate layers.


Advantages for Drupal

1. Infrastructure Simplification

With FrankenPHP, you can:

  • Completely eliminate PHP-FPM
  • Reduce the number of components to maintain
  • Simplify deployment, especially in containers (Docker)

In short, less complexity = less friction.


2. Performance Improvement

The persistent mode offers the possibility of:

  • Reducing request startup times
  • Reusing certain resources and dependencies in memory
  • Gaining response speed, especially on high-traffic sites

This is promising territory for performance-oriented projects.


3. Better Developer Experience

FrankenPHP offers a modern approach suited to current practices:

  • Simple configuration
  • Quick startup
  • Smooth Docker integration

A pleasant experience for developers looking to test or prototype quickly.


Limitations and Caveats

1. Compatibility with Drupal

Drupal was not originally designed for a persistent mode.
This entails several precautions:

  • Management of memory and persistent states
  • Risk of unexpected behavior with certain modules
  • Need for thorough testing before real-world deployment

Each use case merits specific validation.


2. Still a Young Ecosystem

FrankenPHP remains a recent technology:

  • Few real-world feedback from large installations
  • Documentation still evolving
  • Tools and integrations limited, especially on the CMS side

A cautious adoption is therefore recommended for critical projects.


3. Cache and State Management

Drupal has historically relied on a stateless model and an advanced caching strategy.

FrankenPHP's persistent mode may introduce:

  • Side effects in service or user management
  • Cache inconsistencies if application state is not properly managed

A solid understanding of Drupal internals is essential before going further.


Recommended Use Cases

FrankenPHP can be interesting for:

  • Development or testing environments
  • Proof of Concept (PoC)
  • Internal projects or those without high availability requirements
  • PHP performance experiments

Ideal for exploring the next generation of PHP execution.


Cases to Avoid (For Now)

At this stage, it is better to avoid FrankenPHP for:

  • Critical production sites
  • High availability environments
  • Complex or heavily integrated architectures

Caution is advised until the ecosystem matures.


Conclusion

FrankenPHP represents a genuinely interesting evolution for the PHP ecosystem. Its simplified architecture, Docker integration, and performance potential make it worth watching. For Drupal specifically, it works best as a development or experimentation tool today. As community experience grows and compatibility improves, it may become a viable option for broader use. Stay curious, test it in a safe environment, and keep an eye on the evolving ecosystem.