If your Magento store is having performance issues, you may be stumped. Is it the cloud? Are your images too high-res? Is something wrong with the platform itself? Are your third-party extensions or custom API integrations responsible?
Don’t panic. Before you contact your development team to troubleshoot your entire website, consider one of the most common causes of performance drops – unnecessary reindexing!
What is reindexing, why does it happen, and why should you take steps to avoid excessive and unneeded reindexing? Those are great questions, and we’ll answer them all in this blog from 121eCommerce.
What Is Reindexing, And Why Does It Matter?
To begin, let’s discuss the concept of indexing. This is how Magento transforms data into a special type of data table – an “index” – to speed up website performance and improve the shopping experience.
Complex eCommerce storefronts like Magento store a lot of different information, such as:
- Catalog data
- Products and variations
- Stores (for multi-store implementations)
And much more. This information is all stored in different database “tables.” Accessing each one individually all the time would take a lot of processing power, and lead to very slow performance.
The solution is an “index.” This is a special type of data structure that grabs all this different data, transforms it, then stores it in a single set of tables that are faster, easier to access, and offer enhanced overall performance.
However, there’s a catch. The index is, by nature, static. It’s not meant to change constantly, and this is why it offers superior performance compared to manually pulling data from each different set of data.
Need an analogy? Think about it this way. If you need 10 different types of screws and nails, it’s easier to keep them in a single toolbox rather than spreading them across 10 different containers. You can reach in and grab every type of screw or nail you need at once.
But if you need to replace a certain type of nail with a different one, you’ve got to find the right container, grab some nails, and add them to your toolbox. Then, you can get back to work.
Essentially, that’s what reindexing is. It’s the process of pulling new data to replace old data, and update your index accordingly. Data that’s already in the index won’t change until a reindex is performed. For example, if you change the price of an item from $10 to $20, it won’t be updated in your Magento (Adobe Commerce) storefront until it’s been reindexed.
So as the name suggests, reindexing is the process of telling Magento to rescan all of your website’s data. Then, it will update the index accordingly. After you run a reindex, that item price we mentioned will go from $10 to $20 – and all other changes made to your data will take effect.
Why Does Reindexing Slow Down My Magento Store?
So, why does reindexing slow down your store? It’s simple. Scanning all of your data takes a lot of computing power. Your Magento installation will scan every single piece of data in your database to run a full reindexing. This happens even if you only run a partial reindexing (more on that later).
So when a full index is run, these resources are no longer available to the front-end of your website. That leads to some performance deterioration, though the extent of this may vary from store to store.
In a way, you’re trading short-term performance for long-term benefit. Your website will slow down for a little while, but once it’s done, the index allows much faster loading times and better overall performance.
What Causes Unnecessary Reindexing?
Next, you may be wondering why unnecessary reindexing is occurring at your store. Reindexing is necessary for a variety of administrative functions – but if it happens too much, your Magento store may experience performance degradation for little-to-no benefit. The two most common causes of unnecessary reindexing are:
- Administrative actions – A lot of administrative tasks can cause a full reindexing, such as creating a new store or a new customer group. These tasks are, of course, necessary. But when performing a task that requires full reindexing, the store should be set to “Update On Schedule” rather than “Update On Save.” This allows the index to be updated outside of peak business hours. We’ll discuss this more in the next section.
- Third-party extensions – In some cases, third-party extensions that interact with your index may cause frequent, unnecessary reindexing. This support page from Magento has instructions on how to track down the source of unnecessary reindexing due to third-party extensions. If you don’t notice any administrative actions that are causing reindexing, we recommend bringing this up with your technical team so that they can identify the source of the issue.
Best Practices For Reindexing
Now that you know the basics about reindexing and what may cause unnecessary reindexing, how can you avoid this issue? Let’s get into some of our recommended best practices now.
- Use partial reindexing when possible – As the name suggests, partial reindexing only reindexes a small portion of your data. For example, if you change the price on a single product, partial reindexing will only rebuild the database table for the product that was changed. This mitigates the performance impact of full reindexing. Partial reindexing is a native feature of Adobe Commerce (Magento). Make sure it’s implemented wherever it’s practical to do so.
- Check your third-party extensions – As mentioned, third-party extensions often cause full reindexing, and can contribute to other performance issues, too. We recommend performing periodic audits of the third-party extensions you’re using to ensure they are functioning properly, and are not affecting the performance of your store.
- Set your store to Update On Schedule – Whether you’re performing partial or full reindexing, your index should be set to Update on Schedule, rather than Update on Save.
If your store is set to Update on Save, it will begin reindexing altered data as soon as it’s saved. This is not ideal. First, this means your store may reindex data during peak business hours. Second, it means that data will be reindexed many different times if your admin team makes multiple changes during the day.
Setting your store to Update on Schedule means that all of the necessary reindexing will be done simultaneously at a time of your choosing. For example, you can set your indexes to update at 1 AM. Then, all of the changes made during the day will be reindexed at this time – rather than immediately after they are made.
Of course, there are some situations where it’s necessary to Update on Save. But for non-urgent tasks, setting your index to Update on Schedule is always a better option. You can learn more about configuring these options at this link.
- Run full reindexing outside of business hours – No matter when it’s done, full reindexing will cause some performance drops for your Magento store. Because of this, we highly recommend scheduling it outside of peak business hours. You should be able to use your Magento dashboard to determine when site traffic is the lowest, and schedule reindexing accordingly. This way, performance drops will not affect as many customers. And, even if your site does slow down somewhat, this will be much less noticeable due to the lower overall web traffic.
Experiencing Technical Difficulties? Get Help From The Team At 121eCommerce
If you’re an eCommerce entrepreneur, solving technical challenges with Magento on your own can be quite a challenge. So turn to the experts at 121eCommerce. As experts in this eCommerce platform, we’re always standing by to help you troubleshoot your problems, find a resolution, and implement the fix quickly and efficiently.
Whether you’re having a minor issue like unnecessary full reindexing, or you need a complete overhaul of your Magento installation, our team is up for the job.
Interested in learning more? Just contact us online to schedule a quick consultation with our team. We’d be happy to get more details about your project, discuss our expertise, and take the first steps toward resolving your technical issues.