NGINX and cache ... When is it necessary?

June 10, 2016 2.9k views
Nginx PHP WordPress Caching LEMP

I am using NGINX and I’ve come to understand that caching dynamic pages (.php) makes NGINX serve them much faster. However what really happens when a .php page is cached ? Is it just process of copying the HTML output of the .php file to a file on the harddrive on the server so they can be served as static HTML files ?

If this is so, then does that mean that only dynamic pages (.php) can benefit from the process of caching, while originally HTML / Static only pages will not ?

Lastly, would there really be a noticeable difference in speed between the use of FastCGI caching and the WP Super Cache plugin ? (I’ve read that it converts .php files into HTML versions) …

edited by etel
1 Answer

Believe me when I say WPSC (using the HTML cache) is god’s work right there. You’ll notice a huge difference as you won’t even load the database anymore and the pages will renew when you update the post or if a new comment comes in (if you need it to). HTML can also be loaded in gzip form as well as WPSC generates both files per directory.

Have another answer? Share your knowledge.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!