I am debugging an issue with WordPress and I wonder if static files like css/images/js are affected by WordPress/PHP or if they are served directly by apache?

I do not have any WordPress cache plugin active at the moment.

1 Answer 1


Usually: no. When WordPress is running on apache with mod_rewrite enabled, it'll use

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
# END WordPress

To make sure that static files will NOT be served through WP. A plugin might add its own rewrite rules to the .htaccess, but generally WP will not interfere with static files, those will be dealt with by apache directly.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.