Integrations / Platforms / Magento 1 (deprecated) / Prevent Backend Rendering

Prevent Backend Rendering

This integration and its documentation are deprecated and no longer supported.

The Algolia Search for Magento 1 extension is no longer supported (and Magento 1 has reached end of life). However, Algolia does offer a supported extension for Magento Open Source and Adobe Commerce.

In order to save your server resources and make your store faster, you can prevent category and search result pages from backend rendering.

General information and caveats

These pages are powered by Algolia Instant Search feature and when these pages are returned to your user’s browser, it’s immediately re-rendered by JavaScript.

By preventing backend rendering, these pages won’t be generated on the server, which means the server will be able to respond faster and your user won’t have to wait long to see your products. At the same time your server will need much less resources to generate the page.

However, this approach has some caveats.

Most of the website crawlers (including search crawlers like Google, Bing, …) rely on the website code generated on server and cannot properly crawl a page which is generated by only JavaScript on the frontend.

This might lead to non-indexed pages and not following links which would be generated on the server side.

At the same time your server might generate a slightly different page than Algolia does. This page can have different links to a content which is not linked from anywhere else. Which might end up in crawler not being able to access and index those pages.

To bypass those issues, there is a possibility to stop backend rendering for your users but still keep it for crawlers.

Crawlers can be identified by a server by sending it a special User-Agent identifier. In the extension’s configuration you can specify a list of User-Agents for which you want to keep the backend rendering on. The extension checks that User-Agent and if it matches one of the User-Agents in your list, the page will be rendered on the server as well.

Here you can find a list of all search crawlers. The extension by default keeps the backend rendering for “Googlebot” and “Bingbot”.

The feature of preventing backend rendering is highly experimental, and we are not able to guarantee it won’t break accessibility of your website. Please be careful before you enable it.

If you decide to enable the feature, keep an eye on the number of your indexed pages by the tools provided by search engines like Google Search Console or Bing Webmaster Tools.

How to enable

To prevent your pages from backend rendering, navigate to System > Configuration > Algolia Search > Advanced tab. There you can find a setting called Prevent backend rendering? and you can switch it to Yes.

When you switch the setting to Yes, you’ll be able to specify a list of User-Agents for which you want to keep the backend rendering enabled. By default the list contains “Googlebot” and “Bingbot”.

Prevent backend rendering configuration

How it works

When “Prevent backend rendering” is enabled, the extension removes template blocks from rendering by the extension’s layout XML file.

Removed blocks:

  • catalog.leftnav
  • catalogsearch.leftnav
  • tags_popular
  • category.products
  • search.result
  • right.reports.product.viewed
  • left.reports.product.viewed
  • right.poll
Did you find this page helpful?