Magento 2 Google Page Speed Optimizer

Installation and User Guide for Magento 2 Google Page Speed Optimizer

Table of Contents

  1. Installation
    • Installation via app/code
    • Installation via Composer
  2. Configuration Settings for Optimiser Base
    • General Settings
  3. Configuration Settings for Speed Optimiser
    • General Settings
    • Minify HTML
    • Javascript Settings
    • CSS Settings
  4. Configuration Settings for Lazy Loading
    • General Settings
    • Lazy Loading on the Homepage
    • Home Page Excluded from Lazy Loading
    • Lazy Loading on the Category Page
    • Lazy Loading on the Search Page
    • Lazy Loading on the Cart Page
  5. Configuration Settings for Image Optimizer
    • General Settings
    • Compress/Optimize Product Image
    • Compress/Optimize Category Image.
    • Compress/Optimize CMS Image
  6. Configuration Settings for Cache Warmer
    • General Settings
    • Cron Settings
  7. Cache Warmer Grid
    • Regenerate
  8. Console Commands
    • Category Page
    • Product Page
    • CMS Page
  9. Front-end Screenshots
    • Cache Hit for the category page after the execution of category page c ommand
    • Cache Miss for the Category Page
  10. Google Page Speed Tests
    • Home Page Mobile
    • Home Page Desktop
    • Category Page Mobile
    • Category Page Desktop
    • Product Page Mobile
    • Product Page Desktop

Installation

https://docs.scommerce-mage.com/magento-2-extensions/installation-via-composer/installation-via-composer

Configuration Settings for Optimiser Base

Go to Admin > Stores > Configuration > Scommerce Configuration > Optimiser Base

General Settings

image - 2025-06-04T192408.855.png

Configuration Settings for Speed Optimiser

Go to Admin > Stores > Configuration > Scommerce Configuration > Speed Optimiser

General Settings

image - 2025-06-04T192514.900.png

Minify HTML

image - 2025-06-04T192622.109.png

Javascript Settings

Select "Yes" to enable the Defer Iframes

image - 2025-06-04T192719.180.png

CSS Settings

-988888.png

Configuration Settings for Lazy Loading

Go to Admin > Stores > Configuration > Scommerce Configuration > Lazy Loading

General Settings

image - 2025-06-04T193048.312.png

image (90).jpg

image (91).jpg

image (93).jpg

image (94).jpg

image (95).jpg

Configuration Settings for Image Optimizer

Go to Admin > Stores > Configuration > Scommerce Configuration > Image Optimizer

General Settings

image - 2025-06-05T140548.184.png

image - 2025-06-05T140637.713.png

image (96).jpg

image (97).jpg

image (98).jpg

Configuration Settings for Cache Warmer

Go to Admin > Stores > Configuration > Scommerce Configuration > Cache Warmer

General Settings

image - 2025-06-05T141001.711.png

Cron Settings

image - 2025-06-05T141250.705.png

Cache Warmer Grid

When you enable the module and set General Settings > Can Regenerate Cache Manually > to "Yes" then it adds an additional option "Regenerate" under the "Actions ->Select" drop-down at Admin > System > Cache Warmer > Actions. This grid will have Id, Page URL, Page Type - (Home, Product, Category, CMS), Status - (Cached/Un-cached), Last Cached - (Date, Time), and Action- (Regenerate, Delete).

image (99).jpg

image - 2025-06-05T141450.659.png

Console Commands

You can regenerate cache for Product/Category/CMS page(s) by running the following console commands: -

image - 2025-06-05T161924.946.png

image - 2025-06-05T162021.190.png

image - 2025-06-05T162127.923.png

Front-end Screenshots

image - 2025-06-05T162153.478.png

Set Primary Categories

You can use a script provided with the extension to automatically add primary categories for products. Admin can exclude certain categories from primary category and also prioritise one category over the other to be picked as the primary category.

Go to Admin>Catalog>Categories select a category then scroll down to find the option "Primary Category Settings". Here click on "Exclude From Primary Category" to exclude this category from primary category or enter the priority 0 being the highes. The highest priority category will be picked first for the primary category.

image - 2025-06-05T162541.040.png

To automatically assingn primary category for all products run the command given below by going into the root directory of your store.

scommerce:seo-base:set-primary-category

N.B - If you are using older version then run the script provided in the extension folder at the path Data/SetPrimaryCategoryM2.php from ssh

Google Page Speed Tests

Home Page Mobile

image - 2025-06-05T162752.442.jpg

Home Page Desktop

image - 2025-06-05T162857.598.jpg

Category Page Mobile

image - 2025-06-05T162943.469.jpg

Category Page Desktop

image - 2025-06-05T163044.294.jpg

Product Page Mobile

image - 2025-06-05T163113.373.jpg

Product Page Desktop

image - 2025-06-05T163143.522.jpg

If you have a question related to this extension please check out our FAQ section first. If you can't find the answer you are looking for then please contact support@scommerce-mage.com.


Revision #7
Created 4 June 2025 13:38:25 by scommerce
Updated 24 October 2025 09:21:39 by scommerce