Magento performance guide

20.02.2020 Angelika Siczek
person working on a tablet with hologram spreading out of it

The Magento performance guide is written for all versions of e-commerce platforms – both for the Community and Enterprise versions. In addition, the knowledge provided in the guide is used for web applications written in PHP and MySql. It contains tips on optimizing and improving performance for the server and application of your e-commerce store.


If you are not interested in manual optimization, there are also tools that will improve the performance of your application after just a few clicks. They do not require advanced knowledge and are able to improve the store’s operation. JS & CSS Compressor + Image Optimization will compress JS, CSS and HTML files and thus reduce loading time. PotatoCommerce FPC is a module that will cash the page in such a way that it is always ready to be reloaded. The whole process is completely automated and requires only the installation of the above applications.


Magento performance guide



Nexcess offers a full package for store owners on the Magento platform. The only downside is its low availability – only in the United States, Great Britain and Australia. The basic package starts from $ 19.95 per month, but it’s cheaper after purchasing an annual subscription. The basic package offers single IP, 7.5GB of disk space, 16GB of RAM, double Quad Core E5620, 75GB of monthly data transfer, 9 additional stores and 30 accounts per server. Nexcess is the perfect solution for small and medium-sized stores on the Magento platform.



Rackspace is another solution designed for stores on the Magento platform. The company has been in existence since 2008 and has over 1000 clients around the world. The cheapest package from Rackspace costs $ 499 per month. It may seem like a lot, but it can provide a server that will keep 100 visits and 150,000 products simultaneously, will have 146 GB of disk space, 4GB of RAM, Cisco ASA 5505 firewall and 2 TB of transfer per month.



If your Magento store has dynamically generated content from PHP scripts, Nginx from PHP-FPM will be the best solution. For many http / HTTPS connections, Apache simultaneously uses a large amount of RAM and CPU processing power. This problem is particularly great for the Apache configuration with mod_php prefork. Because each Apache process uses 100 MB of RAM, a server with 16 GB of RAM limits the number of queries to 150.


Nginx’s biggest advantage is that it is event-based, while Apache is process-based. This server does not need further processes to increase performance and is therefore very economical in memory consumption. In addition, Nginx uses asynchronous and non-blocking Input and Output. It operates on a certain number of processes, and each of them is single and isolated. Thanks to this it is possible to service many clients for one process.


On Nginx you can profit if you are not going to handle thousands of queries at the same time. It offers the perfect solution for accelerating the operation of your store operating on the Magento platform from the smallest VPS servers to entire server groups.


The downside of Nginx is the lack of mod_php. Nginx cannot control Magento directly and needs a middleware due to the static nature of the web server and the reverse of HTTP / FastCgi. You can use PHP-FPM, which is designed to support heavy-load websites operating on PHP web applications. It does not consume a lot of memory and offers unique features such as adaptive process creation, advanced login with a slowlog for running PHP scripts, the ability to work on various php.ini and uid / gid / chroot / environment, emergency restart in case of damage to the opcode cache, data in real-time about server performance and activity.


To use Nginx in an e-commerce store, you need a frontend with caching, a FastCGI reverse proxy, which will handle all HTTP / HTTP connections, static file delivery and PHP-FPM. In this case, Nginx acts as a FastCGI reverse proxy for all dynamic queries and directs them to the PHP-FPM backend, and then returns the response to the user.


If you use Nginx as the load balance, in the setting of one Nginx frontend and several PHP-FPM backends, it will work as an emergency backend and increase the reliability of Magento installations.


New Relic also has Apdex and notifications. With the help of this tool you can monitor whether Magento works efficiently and at the level of industry requirements. Notifications will let you know immediately if Magento for some reason degraded performance in any zone.



With this addition you will gain full visibility of the Magento platform based on the performance of PHP applications. This solution offers quick installation and a high level of personalization. After installation, this tool automatically recognizes the characteristics of your Magento. You can later choose exactly which data to hide or display in live view. It also distinguishes a web application from a mobile one. You’ll also get real-time error notifications.


Optimized Magento MySQL configuration

The proper configuration of MySQL is one of the most important things you can do to improve Magento’s performance. However, this requires knowledge of the components, mainly the available RAM. Below are the best solutions designed to optimize Magento with the help of properly written MySQL.


### MyISAM #

key_buffer_size = 16M # keep it low if no myisam data

myisam-recover-options = FORCE,BACKUP

### SAFETY #

innodb = force

max_allowed_packet = 150M

max_connect_errors = 100000

bind-address =



back_log = 200

interactive_timeout = 7200

wait_timeout = 7200

net_read_timeout = 120

net_write_timeout = 300

sort_buffer_size = 2M

read_buffer_size = 2M

read_rnd_buffer_size = 16M

join_buffer_size = 4M

tmp_table_size = 128M

max_heap_table_size = 128M

query_cache_type = 1

query_cache_size = 128M

query_cache_limit = 4M

max_connections = 150

thread_cache_size= 32

open_files_limit = 65535

table_definition_cache = 4000

table_open_cache = 4000

### INNODB_ #

innodb_thread_concurrency = 0

innodb_lock_wait_timeout = 7200

innodb_flush_method = O_DIRECT

innodb_log_files_in_group = 2

innodb_log_file_size = 256M

innodb_log_buffer_size = 16M

innodb_flush_log_at_trx_commit = 2

innodb_file_per_table = 1

innodb_io_capacity = 400

innodb_read_io_threads = 8

innodb_write_io_threads = 8

innodb_buffer_pool_instances = 8

innodb_buffer_pool_size = 4G


#log_error = /var/log/mysql/mysql-error.log

#log_queries_not_using_indexes = 1

#slow_query_log_file = /var/lib/mysql/mysql-slow.log


#log_bin = /var/lib/mysql/mysql-bin

#expire_logs_days = 14

#sync_binlog = 1


Knowledge of the Magento database

There are four ways to dramatically improve Magento’s performance and performance.


MariaDB instead of standard MySQL

MySQL is not an obligation. You can find and use other solutions to improve Magento. MariaDB is a tool working with MySQL, but created on an open source basis. It was created under the GNU GPL license by MySQL employees. Main guidelines are maintaining high integration with MySQL, enabling rapid library exchange, and similarity in MySQL and API commands.


MongoGento from Smile Open Source Solutions

You can also use NoSQL instead of MySQL. Just install MongoGento to be able to use the MongoDB module. It reduces the size of the database, but thanks to heterogeneous catalogs designed for millions of products, it remains flexible. Another advantage of this solution is its performance, which does not differ from Magento. The combination of SoIR, MageCache and MongoDB gives a very fast frontend and backend. MongoGento is also based on open source, so it is a great alternative to MySQL. The downside is the lack of compatibility with some additional modules.


Optimization using Tuning Primer

The Tuning Primer script allows developers to view MySQ settings for Magento and make changes to improve the stability and performance of your platform. The script analyzes MySQL and its data and gives recommendations on how to modify server settings. For this tool to work properly, it must be running for 48 hours. Tuning Primer was designed to work with versions of MySQL above 3.23.


Performance improvement with OPcache

OPcache is a module whose operation is based on code cashing. It will improve PHP performance and the performance of the web application on Magento. OPcache uses shared memory to store compiled script byte code, eliminating the need to constantly load PHP scripts with every query.


Using Redis on the Magento platform

Redis, or Remote Dictionary Server, is a server data structure that stores keys with optional persistence. This is one of the most popular Magento tools. E-commerce platforms provide support for many cache backends with many system files, but with the increasing number of queries this solution works worse and worse. They do not have cache grouping support.


Redis outperforms its competitors by offering features that they lack. Includes the ability to create clusters already in the basic version. Further important features are replication and Sentinel. Their combination transforms Redis into a data storage, which towers over Memcached. Other features are strong sorting, hash, list creation, fast Pub / sub, values​​limited to 512 MB, Lua scripting (from 2.6), transaction blocking – watch / multi / exec.


Redis is more flexible than Memcached, but also has more options. Provides greater scaling, availability and administration capabilities. It is a better choice not only for more applications at the same time, but above all for Magento.


How to implement CDN for Magento?

CDN, or Content Delivery Network is a comprehensive service based on many data centers around the world. The main purpose of this type of service is to increase the availability and speed of loading your content on the store’s website. CDNs work with various web objects and store various content for download. They also provide faster access to applications, streaming media and social media. Therefore, CDNs play a very important role in the modern digital world. They are an excellent tool for accelerating the Magento platform. There are many solutions available.


CloudFlare is one of them. It involves the improvement of hard drives, advanced network routing, modern improvement of server technology. New generation CDNs, which CloudFlare belongs to, work better than their competitors. It is more affordable and faster to install. In addition, it provides the fastest connection to the site, the shortest loading time, regardless of the user’s location. This service supports static and dynamic content. CloudFlare guarantees that the store on the Magento platform will always be available online, regardless of the status of your server. Magento has an original extension that can be used to implement the CDN service in your e-commerce store.


Improving the performance of the Magento application

The sales profit directly depends on the performance of your store. Bringing Magento to its maximum potential is a key investment in your business. In addition, the speed of the website is taken into account by search engines when creating website rankings. Pages that load faster will outpace slow pages. That’s why improving Magento’s performance is so important.


Full page cache extension for Magento

There are many Full page cache extensions designed to improve Magento performance. They reduce page loading time and speed up store operations. All modules in this extension group work on the same principle. Magento automatically generates and delivers pages to users who are in the store for the first time. They are copied and saved in cache files. At some point, your store is fully copied, with all subpages and information, so there is no need to generate cache files from scratch. As a result, the Full page cache extension reduces the time it takes to load a page from the database and dramatically speeds up the store’s operation.


Mirasvit Full page cache extension

If you are considering using Full page cache, you must consider the Mirasvit product. This is one of the most reliable and fast solutions on the market. This module significantly speeds up the loading time of a standard Magento website. In addition, it reduces the load on the server you are using. As a result, you get a higher place in the search engine ranking and an increased conversion rate.



There are also other products on the market that will perform well in this role. Extendware has created an extension for Magento that reduces First Byte Time to a minimum and increases the frequency of server queries. Thanks to this, it reduces the database load and makes the Magento platform much more responsive.



The Lesti :: Fpc extension does not require any additional external tools to significantly speed up the store’s work on the Magento platform. It works with events, replacing dynamic blocks before sending any query to the user, and caches cms_page_index, cms_index_index, catalog_product_view and catalog_category_view. This module supports many different types of stores and currencies. In addition, it has typefaces of mobile pages and the ability to create price groups. Most importantly, Lesti :: Fpc is free to download.


Magento extensions to improve cache

If you want to get the full potential of Full page cache, it must work in a team with cache warmers or crawler modules. These modules will scan your e-commerce business and make sure that all pages and content load as quickly as possible. By the way, these tools will refresh old cache pages. Thanks to this, the user will always find the fastest loading page. Cache warmer / crawler will also improve the cache hit rate by caching pages that were not previously in cache memory. As a result, there will be more cache data than queries for non-cached content.


CSS and JS minification

A good way to increase Magento’s performance is to minify the source code in Javascript and CSS files. For assembly, compression and caching, it’s best to use the Fooman Speedster Advaced extension. It collects all Javascript files and combines them into one common file. It does the same with CSS files. This extension not only reduces the overall size of the source code files, but also the number of http queries. As a result, you get faster page load time. The Speedster extension for Magento is free. Extendware Minify JS / CSS / HTML Magento Extension is another competitive tool. It has an intuitive backend section and allows you to configure everything in a very short time.


There is also an extension for Magento that will prepare your website for Google’s requirements for page loading speed. Google Pagespeed Optimization Extension takes all Javascript and Css tags to the bottom and offers backend configuration to disable specific JS and CSS tags. This tool is compatible with Magento versions from 1.5 to 1.9.


Magento cleaning

Thanks to the excellent reporting system, every detail of every query is saved in Magento logs. This, unfortunately, often leads to a reload of the database, which slows down the e-commerce store. Fortunately, there are some tools that deal with cleaning. Keeping the Magento log database in order is a very good way to speed up an e-commerce store. The Magikcommerce blog provides tips on how to keep clean Magento reports. There are also countless topics and forum sections within the Magento community that will help with this issue. And after cleaning the Magento logs, it is worth preventing their reloading in the future. The Yireo_DisableLog module will help in this.


Faster reindex

Quick reindexing is another aspect affecting Magento’s performance that is worth taking care of. Reduces loading time by accelerating the saving of products in the catalog. As a result, the performance of all Magento will increase.



Installing this module significantly improves Magento performance and admin backend speed. Saving products and categories will be even more efficient. Thanks to this, he will be able to do more work in less time


Fast Asynchronous Re-indexing

This module will also help improve the operation of your e-commerce store platform. It will reduce the maximum server load by speeding up administrative work. When adding a new product or changes to an existing product, a process is created that creates a reindexing query for the item data. With the Fast Asynchronous Re-indexing module, the cron process reindexes the data in the background. Admin can then work on editing or adding products without interruptions and without waiting for the changes to finish saving.


Cache Varnish tools

Varnish is designed to minimize the number of disputes between topics. It stores data in virtual memory, and the decision about what will be saved to disk and what in virtual memory is made by the operating system. As a result, you can avoid situations in which data is simultaneously stored by the system and at the same time saved to the application disk. This will significantly improve Magento’s performance.


Turpentine Magento Extension

This extension is created to support Magento and Varnish. With the help of Turpentine, you can add an instant fast reverse proxy to your e-commerce store. The problem is that the standard solution does not cache queries with cookie files, so cookies from the Magento frontend do not go to Varnish. By installing this extension, you add a configuration for Varnish in files and improve the reception of cookies by Magento. As a result, Varnish works for the sales platform.


Improved content cataloging in Magento

The right tool for searching the content of e-commerce stores significantly increases the positive User Experience. There are many tools that improve this aspect of your business by improving search methods and speed.


Sphinx Search Ultimate

This extension will definitely improve the quality of product search in your store. Search Sphinx Ultimate from Mirasvit supports over 660 keywords and understands up to 60,000 synonyms. Allows you to search for products by name, tags or order numbers. The extension is paid and costs $ 149. 


Managed Elasticsearch

Another noteworthy addition is Managed Elasticsearch, which provides advanced full-text search, which is available as an extension to open source. With this Magento module you will enable your clients to search the content very precisely. This module also gives you the option to create attribute names, descriptions, and ordinal numbers as searchable attributes.


Magento extensions for the Enterprise class

Magento Enterprise Clusters from Nexcess is a tool created with the performance of this platform in mind. All of its solutions are based on the latest safety and performance solutions. Each cluster is separately optimized for Magento. All of them provide access to Nexcess CDNs. The basic product is Two-Node Cluster, which is both a web application server and a database server. With this solution you can divide your Magento store into two independent servers. In addition, you will receive additional tools such as an additional firewall. Prices start from $ 1,400 per month.



Rackspace supports more pages on the Magento platform than any competition. It has simple but good templates for customers dealing with the store themselves. Its advantages are the flexibility of architecture and options, support at every step, excellent customer service and excellent performance.



Mgt-commerce, in addition to standard modules and functions, also provides hosting services. By choosing this solution, you will receive additional time to operate your store. It introduces 4 types of Multi server offers. The basic package starts from 249 €.


What are the risks of a slow e-commerce store website?

The performance of any site, not necessarily an e-commerce store, is important for both the owner and the user. Statistics on the impact of slow pages on conversion rates vary by market segment, but low performance will never improve store performance and profitability. According to, free e-commerce sites cost owners £ 8 billion in 2013. In the United States, sellers lost $ 3 billion on shopping sites that are too slow. research has shown that 90% of the best brands on the e-commerce market do not meet the industry’s rule of page loading time under three seconds. What’s more, some charged up to eight seconds. How does this affect customer behavior? 44% of buyers think that the buying process has failed when the site is loading slowly. 33% of customers leave their cart and are looking for an alternative e-commerce store. Delaying the transaction finalization results in a very high basket abandonment rate – up to 80%.


According to OnlineGraduatePrograms research, 25% of users do not intend to wait for page loading for more than four seconds. However, the situation in mobile e-commerce is even more serious. 40% of users leave the site if it loads more slowly than three seconds. Amazon says the delayed loading of the other side of the store costs them up to $ 1.5 billion a year. In turn, Google believes that if they delayed the display of search results by 0.4 seconds, the company would lose 8 million searches per day.


How is the store page speed measured?

However, there are two types of customers – the one that visits the store for the first and first time loading the page, and the one that returns after previous purchases and uses the content of the cache. There are three indicators in measuring their behavior: time to first byte (measuring server responsiveness), rendering start time and loading time. The first indicator shows the time it takes for the server to respond to the user’s query and send the appropriate data. The second one shows the time at which any item will first appear on the page. The third measures the loading time of all elements.


All these indicators are measured under both normal and load conditions. You can test your site at The results will show what exactly slows down your e-commerce website. The most common reasons for slowing down the site are heavy images and many interactive elements, shortcuts embedded in the site or poor hosting services.


Acceleration of an e-commerce store can be a direct factor in the financial profits of running it. The tools available on the market will increase the performance of the Magento platform in many different aspects of its operation. However, the most important tip will be to find the right server that will ensure the fast operation of your store. Remember that even if you have a small store with a small number of products and product descriptions, poor hosting services will be the weakest point of your site. Magento’s performance improvement tools should come as an additional solution. You can also use package products in which the server service and acceleration modules are offered. However, they can be expensive.

Have a question?

Write to us

    PDF, DOC, DOCX, JPG lub PNG (max 5MB)



    Andrzej Szylar

    Chief Executive Officer


    Magdalena Paczyńska-Kamienik

    HR Manager


    Aleksandra Bielawska-Clegg

    HR Business Partner



    Michał Duława

    New Business Developer



    Katarzyna Zajchowska

    Marketing Partner