Apache plus PHP-FPM is a solid default for WordPress—when the wiring is consistent. This guide covers baseline expectations and a quick checklist so you can confirm everything is aligned and know where to look when it isn’t.
Baseline expectations
- Apache serves HTTP and proxies PHP requests to PHP-FPM.
- PHP-FPM runs pools (often per PHP version, sometimes per site).
Checklist
- Confirm Apache proxy/fcgi modules are enabled (environment-dependent).
- Confirm your vhost routes PHP to FPM (socket or TCP).
- Confirm PHP-FPM is running:
sudo systemctl status php*-fpm --no-pager
First-aid commands
- Apache config test:
sudo apachectl configtest - Restart Apache:
sudo systemctl restart apache2 - Tail errors:
sudo tail -n 200 /var/log/apache2/error.log
FAQ
How do I know if PHP requests are going to PHP-FPM?
Check the vhost: it should use ProxyPassMatch or SetHandler pointing to php-fpm (or similar) with the correct socket or TCP address. Then confirm the PHP-FPM pool for that socket is running.
Apache won’t restart after a config change—what next?
Run sudo apachectl configtest and fix any reported syntax errors. See fixing Apache restart failures for a full flow.
Related
- Debugging WordPress after a PHP upgrade — after a PHP version change
- Hosting multiple WordPress sites on one Apache server — per-site setup patterns
- Fixing Apache ↔ PHP-FPM socket mismatches — when the vhost points at the wrong pool