Magento 2 Module – Product Sorting by Popularity
Magento Modules: Clear Guidelines
You purchase the module once, with no domain restrictions
Free installation and updates via Composer
Affiliate Program
Technical support for Magento
Clear guidelines for licensing Magento modules
Magento Module Code Security
Want to increase sales in your Magento store? The Product Sorting by Popularity module is a solution that automatically displays best-selling products in the top positions, increasing their visibility and sales.
How does the module work?
The module installs two new product attributes:
- Popularity – calculates popularity based on actual sales data from the time period you define.
- Custom Popularity – lets you manually set an artificial popularity value for selected products to promote specific items even more effectively.
Popularity calculations are performed automatically using the cron task scheduler every day at 5:00 AM (0 5 * * *). In addition, the module lets you manually run calculations from the Magento admin panel, where you can review the results in real time as clear logs.
Key module features
- Enable and disable the module – easily manage sorting availability.
- Set the calculation period – define how many days of sales data should be analyzed.
- Select order statuses – the analysis includes only orders with the statuses you specify, allowing precise adjustment to your store’s needs.
- Exclude store views – exclude specific store views from the popularity analysis so they do not distort the results.
- Log preview – easy access to product popularity calculation results in the admin panel.
Benefits of using the module in your Magento store
- Higher sales – products with high popularity appear at the top of the list, naturally increasing their conversion potential.
- Merchandising automation – save time with automated sales analysis and product sorting.
- Promotion of selected products – manually increase popularity using the custom_popularity attribute.
- Flexible configuration – full control over the data analyzed by the module.
- Transparency and control – access to logs lets you continuously monitor the effectiveness of popularity calculations.
The marketing importance of proper product presentation
Proper presentation of your product offering is a key element in the success of any online store. Customers most often make purchase decisions based on what they see first. Highlighting bestsellers and the products that generate the most interest has a positive impact on conversion and builds a positive store image. With automatic sorting by popularity, you can execute your marketing strategy more effectively, resulting in higher sales and greater customer satisfaction.
Who is this module for?
The Product Sorting by Popularity module is a great fit for any Magento store that wants to increase sales and effectively promote bestsellers. It makes it easy to increase the visibility of the most sought-after products.
SEO and Magento store optimization
By using sorting by popularity, you also improve the user experience, which has a positive impact on your store’s SEO. High product popularity indicates attractiveness, which may lead to increased organic traffic and better positions in search results.
Summary
The Product Sorting by Popularity module is an effective and simple tool that will improve the sales performance of your Magento store. Start showcasing your bestsellers today and watch your sales results grow.
Installation and Configuration Guide for the 'Product Sorting by Popularity' Module for Magento 2
1. Installing the module via Composer
Follow the steps below to correctly install the module in your Magento 2 store:
Step 1: Add repositories to the Composer configuration
composer config repositories.popularity vcs https://github.com/kowalco/module-popularitycomposer config repositories.attributes.query vcs https://github.com/kowalco/magento-2-attributes-queryStep 2: Add an access token for the private GitHub repository
composer config --global --auth github-oauth.github.com Step 3: Install the module using Composer
composer require kowal/module-popularityStep 4: Enable the module in Magento 2
php bin/magento module:enable Kowal_PopularityStep 5: Apply database updates
php bin/magento setup:upgradeStep 6: Flush the Magento cache
php bin/magento cache:flush2. Module configuration in the Magento admin panel
After installing the module, go to the Magento admin panel and complete the steps below:
a) Module settings:
- Go to Stores → Configuration → Kowal → Popularity.
- Enable or disable the module using the 'Enable Module' field.
- Set the popularity analysis period in days in the 'Sales Analysis Period' field.
- Select the order statuses that should be included in the popularity analysis.
- Select the store views that should be excluded from popularity calculations.
- Save the configuration.
b) Setting sorting by the 'popularity' attribute:
- Go to Stores → Configuration → Catalog → Catalog → Product Listing.
- In the 'Available Sort By' section, make sure the 'Popularity' attribute has been added.
- In the 'Default Sort By' section, you can set 'Popularity' as the default product sorting method.
- Save the configuration.
After completing these steps, your Magento 2 store will automatically sort products by their popularity.
Version: 1.0.6
04/15/2025
Enhancement
Added the ability to sort products by the popularity attribute in the PageBuilder widget – Product List and Product List Slider. The new 'Popularity (descending)' option allows the most popular products to be displayed at the beginning of the list, according to the value of the popularity attribute.













