How to SpeedUp your magento website ?
Normally magento website loading time will get more. Due to this issue, you may loose your customers.But loosing of customers is a kind of loosing your business.
Why slow ?
Basically magento is developed with EAV structure.Using EAV is good. But, storing a one value into the database, we should use minimum 4 tables at-lease.Similarly if you want to fetch one product value from DB then at-least you have to refer min 4 table.If will reflect into website.
Ex: For getting a category information we have join below table.
1. catalog_category_entity
2. catalog_category_entity_datetime
3. catalog_category_entity_decimal
4. catalog_category_entity_int
5. catalog_category_entity_text
6. catalog_category_entity_varchar
Not only EAV is the drop back in your website, due to joining of table and fetching of values it may take some delay.
Similarly, lot of things we need consider when we move the live server.
Way to Speed Up your website:
In some of the below ways we can speedup our magento website,
1. Server – First we need to consider our SERVER. Try to use,height and lightweight web servers.
2. RAM – Typically your Magento website will run and fine with the help of 512MB RAM. But when we are enabling Xcache or APC , PHP opcode then we need to consider the RAM also. Try to use more than 512MB it may helpful to speedup the website.
3. Disable Unused module in your magento installation.
4. Basically loading of image is getting slow in website. For the i suggest go with CDN. Fetch your website product images from CDN.
5. Enable Magento Cache and clear magento cache at-least once in a day.
6. Enable Flat Categories and Products.
Fetching a product or category detail from with the help of joining multiple table and object, just enable flat from admin.We can refer a single database table with single object.
7. Merge and minify CSS and JS Files. If possible try to load CSS and JS files from CDN. Instead of fetching it from your magento installation.
8. Enable Compilation Ex: Admin -> System -> Tools -> Compilation, click Enable.
9. Enable GZip Compression or do .htaccess file code change – If .htaccess then “Mod_deflate” allows output from your server to be compressed.
10. Enable Apache KeepAlives. We can set some alive time also. But keep always alive.
11. Optimizing Magento Template also one the way to speedup magento website.
12. Do some MySql Configuration: like below
key_buffer = 32M
innodb_autoextend_increment=512
max_allowed_packet = 16M
max_heap_table_size = 256M
read_buffer_size = 2M
read_rnd_buffer_size = 16M
bulk_insert_buffer_size = 64M
myisam_sort_buffer_size = 128M
myisam_max_sort_file_size = 10G
myisam_max_extra_sort_file_size = 10G
myisam_repair_threads = 1
13. Disable the Magento log
System -> Configuration -> Advanced -> Developer -> Log Settings (default is disabled)
If following above way, we can speedup our magento website.