13 Ways to Boost Magento Performance With Increased Speed

13 Ways to Boost Magento Performance With Increased Speed

When it comes to eCommerce storefronts, many businesses opt for Magento. Why? It is a very powerful platform that can be scaled to fit your precise requirements. This means that as your business grows, your eCommerce platform will be able to grow with you.

One of the biggest frustrations with Magento falls into the category of performance, especially when talking about speed. Fortunately, there are some strategic steps you can take to reduce issues with the performance speed of your Magento eCommerce storefront. The points covered in the article include:

  • Most recent version
  • Use browser caching
  • Configure MySQL
  • Optimized images
  • Enable flat catalog
  • Concatenate (merge) CSS and Javascript
  • Reduce the visible content size
  • Enabling Magento compilation
  • Maintain database & log files
  • Reduce extensions & modules
  • Opt for fast web hosting.

Best Ways of Magento Speed Optimization

Magento Speed Optimization

  1. Most Recent Version

Visit Magento to find out if you are using the most recent version of their product. If you find that this is not the case, you can update it by following the detailed instructions. It is important to run the latest Magento version because, as a rule, with the release of a new version, Magento fixes bugs and improves performance.

Steps to Upgrade Magento:

  • Install the latest version of Magento
  • Run the installer
  • Move over themes and custom extensions from old to the new version

If you do now want to deal with upgrading Magento yourself, you can always ask for professional support.

  1. Use Browser Caching

Web pages that you have previously visited are stored in your computer's memory so that the next time you visit them, they will be able to load faster. This is what browser caching is all about. Snippets may be added to your Magento eCommerce .htaccess files in order to take advantage of these performance opportunities.

Go to the backend menu System > Cache Management and double-check the settings. It should all be green. What could the reasons for the cache being off? There are plenty of them: a 3rd-party developer, integrator, or someone in-house just forgot to turn it on. So if your site suddenly becomes slow and unresponsive – check cache settings.

Many forms of caching can be implemented. You can combine Nginx + APC + Varnish Caching + Memcache to get the best result.

  1. Configure MySQL

Improve performance by caching your MySQL data. These settings can help your process:

my.cnf

query_cache_type = 1

query_cache_limit=2M

query_cache_size = 32M

php.ini

php_value memory_limit 512M

Every time a Magento page is loaded, there are a series of database queries made, and the database server must go to work. The long query process takes time, and there is slower disk access, which results in lower performance.

Solution: MySQL has a built-in configuration parameter known as query_cache_size. This helps to store the result of the query in memory, which is much faster than accessing from disk.

Main Techniques to Speed Up Magento 2

  1. Optimized Images

Images take up more space on your Magento eCommerce platform than most any other element. That's why you need to be sure that they are as compressed as possible. Use PhotoShop to take care of file compression before uploading your images.

Alternatively, there are extensions like TinyPNG that can be used for compressing images that have already been uploaded to your Magento platform.

Benefits of optimizing images:

  • It can dramatically increase the speed of your pages.
  • Images can be compressed before uploading with tools like PhotoShop or other auto-optimize tools.
  1. Enable Flat Catalog

Magento is based on the EAV model (entity attribute value) to store product and customer data. Big Magento stores (1000+ products) can see increased speed and performance by merging all data into a single table, which allows for a faster response time when MySQL queries are initiated.

What happens when you enable the flat catalog?

  • It will help to speed up your product collection instead of managing the catalog data in many tables by the Entity Attribute Value (EAV).
  • Improves performance by responding to MySQL queries faster.
  • Beneficial for those eCommerce stores having 1000+ products.

How to do?

  • Go to “Stores” → “Configuration” → “Catalog.”
  • Under “Storefront” change “Use Flat Catalog Category” and “Use Flat Catalog Product” to “Yes.”
  • After this, “Save Config” and clear the cache.
  1. Concatenate (merge) CSS and Javascript

Just as you were able to put all products into a single table, CSS and JavaScript files can be merged into a single file. Doing so reduces the number of HTTP requests, thereby speeding up your Magento storefront.

There is an inbuilt feature in Magento version <2 that will help you combine CSS and JavaScript files:

  • Navigate to “System”, then go to “Advanced” and further, go to “Developer”.
  • Under “JavaScript Settings” and “CSS Settings”, change the dropdown to “Yes” and then “Save Config.”
  • After combining the files, clear the cache.
  1. Reduce Visible Content Size

If there are contextual items that do not need to be a part of your Magento page, remove them. The less your browser has to manage at each page, the faster the performance will be realized.

Magento Site Speed Optimization

  1. Maintain Database & Log Files

Default settings with Magento have logs kept for 180 days. If you change the log files to between 7 and 14 days, you will still have a backlog to reduce the size of your database.

  1. Reduce Extensions & Modules

Users tap into Magento extensions and modules to increase the power of the platform. Unfortunately, which can lead to the increase of HTTP requests as well as build up the number of CSS and Javascript files that you need to deal with.

That's why you need to be very selective about the types of extensions and modules you use on your Magento platform while tapping into only the best extensions and modules available.

For disabling the modules, you can follow these steps:

  • Navigate to “Stores” → “Configuration” → “Advanced”→ “Advanced”.
  • Click “Disable” on the modules you don’t need. Further, select “Save Config.”
  1. Opt Into Fast Web Hosting

Most of the Magento owners make the biggest mistake here. By choosing a poor web hosting provider, you have to always worry about uptime. Along with all of the points above, it is necessary to opt into high-quality web hosting for your Magento project. The hosting plan you choose plays a vital role in the overall website’s performance.

As a result, avoiding shared hosting even though the expense of such can be far less than the fast web hosting alternative. However, considering the amount of power that you require for your Magento eCommerce store to operate it simply doesn't make sense to take shortcuts when it comes to hosting your project on the right platform.

  1. Turn Production Mode On

Magento 2 has three modes of operation:

  • default
  • developer
  • production

The fastest one is production. Default and developer modes are used for debugging purposes and should never be used for a live site. You will need to get SSH access details from your hosting provider to find out what mode your website is running in now.

  1. Never Use JS Bundling

JS bundling is a special feature of Magento 2. It is supposed to cut down a number of HTTP requests required to load a page by grouping JavaScript files. While the feature was designed to improve performance, in reality, it can give an opposite result. If you activate JS bundling it would create a huge 5-10Mb file with all the JavaScript code. The file that big would negatively impact page load time.

In the past, a big number of elements on a web page resulted in a decrease of performance, but now M2 web hosts should run SSL and HTTP2. You can double-check JS bundling is off by going to backend menu Stores > Configuration > Advanced > Developer. With Magento 2.2+ these settings are only visible in developer mode.

  1. Autoscaling. 

Nowadays, some hosting companies offer automatic capacity scaling. The server itself allocates power for the site when they are actually needed. Server resources are scaled up and down in accordance with real-time traffic conditions. So, in the case of holiday seasons when online stores usually see the surge in traffic, autoscaling will add additional servers to handle it. When you have less traffic, the capacity will automatically become lower.

Concluding Thoughts About How To Boost Magento Performance

Magento 2 (M2) comes as a new era of e-commerce innovation. It has more features and is more complex, and has more lines of code, compared to the first generation of this popular platform. This CMS system comes equipped with various performance optimization features. It is really a hard job to configure them properly. Make sure all Magento 2 caching options are enabled. CSS/JS minification must be enabled, and it is important to run M2 in production mode always. Never use JS bundling, as it brings more harm than good.


Do you want to increase the performance of your Magento website? 

GoMage professionals will perform an in-depth analysis of your Magento website and suggest the best solutions for performance increase.

Feel free to contact us