Prestashop is yet another popular opensource eCommerce platform written in php. We're releasing a module for Prestashop that allows for optimal full page caching with the Peakhour service. This allows for long lived caching of pages at the Peakhour edge, which get updated with the latest version when it is changed at Prestashop.
Full Page Caching dramatically improves load times by cutting out the time it takes for a CMS to generate a dynamic page. This is typically anywhere between half a second for a quick page, to 3-5 seconds for a slow one. Seeing is believing, here is a cache miss and hit from our client fatburnersonly.com.au:
Nearly 2.5 seconds has been taken off the time to first byte and largest contentful paint! That's without having to change anything with your website.
Tag Based Flushing
Like all our recent plugins, the Prestashop plugin adds a header with tag metadata for each cacheable page. This header is called X-Prestashop-Tag and contains the IDs of each relevant entity that is on the page, eg products, categories, brands, pages, etc. This meta-data gets stored alongside the cached page, then, when an entity gets changed in the Prestashop admin, eg a product price gets updated, then the plugin issues a flush by tag request to Peakhour. Peakhour finds all the pages that have the associated tag and invalidates them in the cache. The next request for the page gets passed through to origin and then re-cached.
TTL (Time to live) is the amount of time a resource lives in a cache before the cache will check for a new version, you can control this within the plugin. The plugin then sets the peakhour-cdn-cache-control header, part of the new cdn-cache-control specification, so only Peakhour will respond to the cache directive.
Ajax Mini Cart
Mini carts are common dynamic sections of eCommerce websites that can prevent caching. The Peakhour plugin makes these load via Ajax so the maximum amount of pages are cacheable.
The same page can present different information depending on a variety of factors, eg whether a user is logged in or not, or if the store is multicurrency and the currency changes. The Peakhour Opencart plugin caters for this by changing a cookie value when these change and makes separate cache regions for the different possibilities.
The Peakhour Prestashop plugin can make a big difference to the performance of your store. Our client fatburnersonly.com.au have improved their 'good' webvitals scores by 20% in the two months they've been utilising Peakhour.