How to speed up Magento 2 Website? - What are the effective checklist for it?
- Inspect Server and System Requirements;
- Htaccess settings;
- Use built-in profiler;
- Using Varnish cache;
- Speed up Checkout process;
- MySQL configuration optimization;
- Enable CDN;
- Change to Production mode;
- Merge/Minify CSS and Js Files;
- Enable flat products and categories;
- Always use latest version of Magento 2.
Make sure all cache types are enabled (
bin/magento cache:status and
bin/magento cache:enable if they're disabled). It's faster to flush the cache types everytime you make changes than to have them disabled.
When you're ready to publish your site put it in production mode (
bin/magento deploy:mode:set production). This will generate classes and deploy static content - please note that it's hard to make changes (js and css) after this so don't do it unless you're done.
Before going into production mode enable css and js minifying and merging and js bundling (see Stores > Configuration > Advanced > Developer section); please note that this is only visible in developer mode.
Optimize images (I recommend using https://tinyjpg.com/), refractor your code:
- make sure you don't use nested
- never load model entites in loops (
$product = $this->_product->load($item->getId())or something like that)
- search throough your layout xml files and make sure there are no blocks with
cacheable="false"since this disables caching for the entire page where it is rendered (read more here https://devdocs.magento.com/guides/v2.2/extension-dev-guide/cache/page-caching.html)
This is what came out of my mind, hope it helps you :)
You want to speed up magento 2 website follow below steps.
Steps to Optimize Performance.
Step 1) Enable Flat Categories and Products Step 2) Merge CSS and JS Files Step 3) Content Delivery Network Step 4) Caching Step 5) Image Optimization Step 6) Enable Compression Step 7) Reduce Server Response Time Step 8) Magento Updates
Hope this help!