Magento 2 Speed Optimze

 Basic

1. Merge css and js.
By Run below command you can find out which mode is active.
php bin/magento deploy:mode:show

On Developer mode
go to Stores > Configuration > Advanced > Developer
Merge css file
Minify css file
On Production mode
php bin/magento config:set dev/css/merge_css_files 1
php bin/magento config:set dev/css/minify_files 1

Js merge
php bin/magento config:set dev/js/merge_files 1
php bin/magento config:set dev/js/minify_files 1

rm -rf pub/static/frontend/
php bin/magento setup:static-content:deploy -f
2. Enable Cache.
php bin/magento cache:status
php bin/magento cache:enable
php bin/magento cache:disable

Advace
3. Configure Radis Cache.
4. Configure Varnish Cache.
5. Configure CDN.

Additional Advace
6. Implement Cloudflare.
7. Load balancer.
8. Containerise.

Code Base
9. Implement lazy load.

How to check if Magento is running in production mode or developer mode

If you want to know. your Magento 2 website is running on which environment you can run below command on terminal and very easily you can kn...

Popular Posts

Posts