# Infinite Scroll PrestaShop — Installation and Configuration Guide

> Installation Infinite Scroll PrestaShop installs like any other PrestaShop module, with no dependency or third-party library. In the back office, open Modules > Module Manager then click Upload a module.…

- Page: <https://www.datafirefly.com/en/documentation/scroll-infini-prestashop/>
- Language: en
- Last updated: 2026-07-15
- Other languages: [fr](https://www.datafirefly.com/documentation/scroll-infini-prestashop/index.md), [es](https://www.datafirefly.com/es/documentation/scroll-infini-prestashop/index.md), [de](https://www.datafirefly.com/de/documentation/scroll-infini-prestashop/index.md), [it](https://www.datafirefly.com/it/documentation/scroll-infini-prestashop/index.md), [pl](https://www.datafirefly.com/pl/documentation/scroll-infini-prestashop/index.md), [pt](https://www.datafirefly.com/pt/documentation/scroll-infini-prestashop/index.md), [nl](https://www.datafirefly.com/nl/documentation/scroll-infini-prestashop/index.md)
- Index: <https://www.datafirefly.com/en/documentation/llms.txt>

## Installation

Infinite Scroll PrestaShop installs like any other PrestaShop module, with no dependency or third-party library.

1. In the back office, open **Modules > Module Manager** then click **Upload a module**.
2. Select the provided `dfinfinitescroll-1.0.0.zip` file and run the installation.
3. Once installed, click **Configure** to reach the settings.

The module adds no database table and sets no override. Uninstalling leaves no trace behind.

## The three loading modes

Loading behaviour is chosen in the **Loading mode** setting.

### Hybrid (recommended)

The first pages load automatically as the visitor scrolls, then a "Load more products" button takes over once the threshold is reached. This is the best trade-off: the experience stays smooth at the top of the list, but the visitor keeps control and the footer becomes reachable again.

### Pure infinite

All following pages load automatically as the bottom of the list approaches, with no button. Best kept for catalogs where footer access isn't critical.

### Button only

No automatic loading: the visitor clicks "Load more" for each page. Useful to limit the number of requests or keep very explicit pagination.

## Available settings

- **Loading mode** — hybrid, pure infinite or button only.
- **Auto-loaded pages (hybrid)** — number of pages loaded before the button appears. Default: 3.
- **Sync URL and canonical** — updates the address bar, the canonical tag and rel prev/next links as the visitor scrolls.
- **Restore exact position** — re-injects the pages already seen and snaps the view back to the visited product when returning from a product page.
- **Enable on all listing pages** — categories, manufacturers, suppliers, search, best sales, new products, price drops. Disabled, the module applies to categories only.
- **Button label** — multilingual label of the "Load more" button.
- **Product list selector (advanced)** and **Pagination selector (advanced)** — see the custom themes section.

## Pagination stays SEO-friendly

Unlike modules that replace pagination with an invisible AJAX call, Infinite Scroll PrestaShop relies on your theme's native paginated URLs. Concretely:

- **Without JavaScript** (bots included), the store shows exactly your usual server-side pagination, fully crawlable.
- **With JavaScript**, the canonical tag and rel prev/next links are updated to reflect the page actually shown on screen, in both scroll directions.

Keep the "Sync URL and canonical" option on: it's what guarantees that the URL shared by a visitor who scrolled to page 4 actually points to that page.

## Exact position restore

This is the heart of the module. When a visitor clicks a product after scrolling, the module stores in session storage: the loaded pages, each one's exact URL, the scroll position and the clicked product ID. It also caches the pages' content, with a size guard.

On return (browser back button or internal navigation from the product page), the module:

1. re-injects the pages instantly from cache, or re-downloads them in parallel if the cache was too large;
2. snaps the view precisely to the visited product, via its ID, with a scroll-position fallback.

The restore state expires after 30 minutes and is never applied on a direct visit to a page 3-style URL: in that case, the page behaves normally.

## Custom themes: advanced selectors

By default, the module targets the classic theme's selectors: `#js-product-list .products` for the product list and `.pagination` for the pagination block. If your theme uses a different structure, fill in the two advanced fields:

- **Product list selector** — the direct container of the product cards.
- **Pagination selector** — the block holding the "next" link (rel next or next class).

No code change is needed. The module re-attaches the injected products' behaviours through application events, letting your theme or other modules re-wire their widgets on the new cards.

## Faceted search compatibility

The module is compatible with the faceted search module. It listens to the product-list update event fired on every filter change, cleanly re-initializes and restarts from the filtered paginated URLs. No extra setting is required.

## Troubleshooting

### Infinite scroll doesn't trigger

Check that the advanced selectors match your theme, and that native pagination (with a "next" link) is present on the listing page.

### The return doesn't snap to the right product

Make sure your theme's product cards expose the product ID attribute. On a heavily customized theme that doesn't expose it, the module falls back to the scroll position.

### On network failure

The module automatically falls back to the native pagination links: navigation always remains possible.
