Fixing Apache ↔ PHP-FPM socket mismatches

apachephp-fpmphpwordpresstroubleshooting

Apache pointing at the wrong PHP-FPM socket (or one that doesn’t exist) is a reliable way to get 500 or 503 errors. This guide helps you verify the wiring and fix it.

Symptoms

Quick checks

Fix pattern

FAQ

How do I know which socket my vhost is using?
Search the vhost config for php-fpm, unix:, or fcgi://. The path or port should match a pool in /etc/php/*/fpm/pool.d/. After changing PHP version or pool config, this is the first place to check.

We have multiple PHP versions—could that cause this?
Yes. See PHP version drift on multi-site servers for how mixed versions creep in and how to document and align them.