Tested on:
Nginx 1.19.0
WordPress 5.4
PHP 7.2.24
Vesta CP
After switching from Apache to Nginx with PHP-FPM, you may notice that the homepage loads fine, but all other URLs return 404 (Page Not Found). This issue is very common when migrating WordPress sites from Apache to Nginx.
Let’s understand why this happens and how to fix it quickly.