{"slug":"wp-rocket-configuration","title":"WP Rocket Configuration","tags":["wp-rocket","caching","performance","minification","elementor"],"agent_summary":"WP Rocket recommended settings for Elementor sites: cache tab, file optimization (no combine CSS/JS), media lazy loading, preload, advanced rules for WooCommerce exclusions, Cloudflare add-on setup, and WP-CLI cache clear commands.","trigger_phrases":["wp rocket setup","wp rocket settings","wp rocket elementor","wp rocket cloudflare","wp rocket woocommerce","wordpress caching plugin","minify css wordpress","delay javascript wordpress"],"runnable":true,"markdown":"\nWP Rocket is the preferred caching and performance plugin. Correct settings matter — wrong configuration breaks sites.\n\n## Cache Tab\n\n| Setting | Value | Notes |\n|---------|-------|-------|\n| Enable caching for mobile | ON | — |\n| Separate cache for mobile | OFF | Unless using different mobile theme |\n| User cache | OFF | Enable only for membership sites |\n| Cache lifespan | 10 hours | Increase for static sites |\n\n## File Optimization Tab\n\n| Setting | Value | Warning |\n|---------|-------|---------|\n| Minify CSS | ON | Safe |\n| Combine CSS | **OFF** | Breaks Elementor |\n| Minify JS | ON | Safe |\n| Combine JS | **OFF** | Breaks plugins |\n| Load JS deferred | ON | Test thoroughly |\n| Delay JS execution | ON | Test — can break sliders |\n| Remove unused CSS | ON | Safe for most Elementor sites |\n\n## Media Tab\n\n| Setting | Value |\n|---------|-------|\n| Lazy load images | ON |\n| LazyLoad iframes/videos | ON |\n| Replace YouTube thumbnails | ON |\n| WebP compatibility | ON |\n\n## Preload Tab\n\n| Setting | Value |\n|---------|-------|\n| Activate preloading | ON |\n| Preload links | ON |\n| Prefetch DNS requests | Add: Google Fonts, GTM, analytics domains |\n\n## Advanced Rules\n\nNever cache these URLs:\n```\n/wp-admin/\n/checkout/\n/cart/\n/my-account/\n/wp-login.php\n```\n\n## WP Rocket + Cloudflare Add-on\n\n1. WP Rocket > Add-ons > Cloudflare\n2. Enter: Email address, Global API Key, Zone ID\n3. Enable: \"Optimal Settings\" and \"Auto-purge Cloudflare cache on update\"\n\n## WP-CLI Cache Operations\n\n```bash\n# Clear all WP Rocket cache\nwp cache flush\n\n# WP Rocket specific clear (if plugin CLI available)\nwp rocket clean --confirm\n\n# Preload cache after clearing\nwp rocket preload --confirm\n```\n\n## Lighthouse Score Targets\n\nAfter WP Rocket + Cloudflare + ShortPixel:\n- Performance: 90+\n- LCP: < 2.5s mobile\n- CLS: < 0.1\n- TTFB: < 200ms on WPX, < 300ms on shared hosting\n","html":"<p>WP Rocket is the preferred caching and performance plugin. Correct settings matter — wrong configuration breaks sites.</p>\n<h2>Cache Tab</h2>\n<p>| Setting | Value | Notes |\n|---------|-------|-------|\n| Enable caching for mobile | ON | — |\n| Separate cache for mobile | OFF | Unless using different mobile theme |\n| User cache | OFF | Enable only for membership sites |\n| Cache lifespan | 10 hours | Increase for static sites |</p>\n<h2>File Optimization Tab</h2>\n<p>| Setting | Value | Warning |\n|---------|-------|---------|\n| Minify CSS | ON | Safe |\n| Combine CSS | <strong>OFF</strong> | Breaks Elementor |\n| Minify JS | ON | Safe |\n| Combine JS | <strong>OFF</strong> | Breaks plugins |\n| Load JS deferred | ON | Test thoroughly |\n| Delay JS execution | ON | Test — can break sliders |\n| Remove unused CSS | ON | Safe for most Elementor sites |</p>\n<h2>Media Tab</h2>\n<p>| Setting | Value |\n|---------|-------|\n| Lazy load images | ON |\n| LazyLoad iframes/videos | ON |\n| Replace YouTube thumbnails | ON |\n| WebP compatibility | ON |</p>\n<h2>Preload Tab</h2>\n<p>| Setting | Value |\n|---------|-------|\n| Activate preloading | ON |\n| Preload links | ON |\n| Prefetch DNS requests | Add: Google Fonts, GTM, analytics domains |</p>\n<h2>Advanced Rules</h2>\n<p>Never cache these URLs:</p>\n<pre><code>/wp-admin/\n/checkout/\n/cart/\n/my-account/\n/wp-login.php\n</code></pre>\n<h2>WP Rocket + Cloudflare Add-on</h2>\n<ol>\n<li>WP Rocket > Add-ons > Cloudflare</li>\n<li>Enter: Email address, Global API Key, Zone ID</li>\n<li>Enable: \"Optimal Settings\" and \"Auto-purge Cloudflare cache on update\"</li>\n</ol>\n<h2>WP-CLI Cache Operations</h2>\n<pre><code class=\"language-bash\"># Clear all WP Rocket cache\nwp cache flush\n\n# WP Rocket specific clear (if plugin CLI available)\nwp rocket clean --confirm\n\n# Preload cache after clearing\nwp rocket preload --confirm\n</code></pre>\n<h2>Lighthouse Score Targets</h2>\n<p>After WP Rocket + Cloudflare + ShortPixel:</p>\n<ul>\n<li>Performance: 90+</li>\n<li>LCP: &#x3C; 2.5s mobile</li>\n<li>CLS: &#x3C; 0.1</li>\n<li>TTFB: &#x3C; 200ms on WPX, &#x3C; 300ms on shared hosting</li>\n</ul>\n"}