Fine tuning nginx & wp rocket cache for woocommerce

I’m curious about certain things about caching settings:

  1. If I have nginx caching, is there a need for wp rocket’s page cache?

  2. Are there any unwanted consequences if I remove wordpress_logged_in cookie from nginx excludes but keep the account, cart, checkout rules?

  3. I’m thinking about improving the user experience by removing wordpress_logged_in caching my woocommerce archive pages like shop, category archive, etc. to improve my page speed while filtering. Are there any caveats to this and what should I watch out for?

Extra: How can I tune redis for woocommerce and is mysql-tuner worth the time on a new trellis site?

  1. If I have nginx caching, is there a need for wp rocket’s page cache?

It really depends. Nginx micro caching means you get cache misses every ~30 seconds (or whatever you set it to). In many situations, that’s perfectly fine. In others you might want a longer-lived cache.

Personally I’d start with Nginx only because it’s very lightweight with almost no chance of anything going wrong.

  1. Are there any unwanted consequences if I remove wordpress_logged_in cookie from nginx excludes but keep the account, cart, checkout rules?

Again, it depends :smile: If your site doesn’t have any personalizations based on logged in users, then it’s safe to remove. If you miss anything in your templates that displays per-user information, then you’re going to cache that one user and show it all other users (which would probably be very bad).

But if you don’t use WP user accounts or the login system on your site (excluding admin of course), then you could remove it. But at the same time, no one would have that cookie set so it doesn’t matter anyway?

  1. I’m thinking about improving the user experience by removing wordpress_logged_in caching my woocommerce archive pages like shop, category archive, etc. to improve my page speed while filtering. Are there any caveats to this and what should I watch out for?

Can’t really say, but again, be careful with caching rules due to leaking cache user information.

Extra: How can I tune redis for woocommerce and is mysql-tuner worth the time on a new trellis site?

No idea. Maybe other people have done this or used that tool.