These are rewrite rules for apache: RewriteBase / RewriteCond %{REQUEST_URI} !\.(gif|jpeg|png|jpg|bmp)$ RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . index.php [L] How to change these rules for nginx?