Custom Category Sorting Engine with Cluster Logic
Challenge
Category pages were broken in Bestseller sort mode: spare parts and accessories appeared before flagship products because the default bestseller ranking treated all products equally. Multiple previous fix attempts had left the issue partially resolved at best, for nearly two years.
What Was Built
A dedicated database table is populated as part of the standard catalog category product indexer run. Products are placed into two clusters before any sort key is applied: Cluster 1 (main products) and Cluster 2 (accessories and spare parts, identified via category membership and configurable in system config). Within each cluster, Recommendation sort applies manually set position weights; Bestseller ranks by actual sales data - also cluster-aware, so an accessory can never outrank a main product regardless of sales volume. Both sort modes work across all storeviews with no content management overhead.
Outcome
Category pages now surface the right products first. The solution is fully index-driven and maintenance-free from the merchant's perspective.
Have a similar challenge?
Get in touch - no sales pitch, just a straightforward conversation.