Magento Compare Products: How to Disable It
[Updated: March 13, 2026]
Magento's Compare Products feature lets customers evaluate items side by side. It ships enabled by default with no admin toggle to turn it off.
This guide covers three proven methods to disable it and best practices for product comparison pages.
Key Takeaways
-
Magento Compare Products creates a side-by-side table of product attributes, prices, and ratings to help customers decide faster.
-
There is no admin panel toggle to disable the feature. You need XML layout changes, a free extension, or template edits.
-
The XML layout method removes compare buttons from all pages without modifying core files.
-
Free extensions from BSS Commerce, CodeDecorator, and others offer one-click disable without code changes.
-
Admin settings control the "Recently Viewed/Compared" widget but do not disable the core compare feature.
What Is Magento Compare Products?
Magento Compare Products = A built-in feature that generates a structured comparison table for selected products. Customers click "Add to Compare" on product or category pages, then view attributes, prices, and ratings in one place.
Perfect for: Electronics stores, B2B catalogs, any store with products that differ on technical specifications.
Not ideal for: Fashion, food, low-price accessories where attributes matter less than visuals.
The comparison table displays product descriptions, key attributes, use cases, and customer ratings. There is no default limit on how many products can be compared at once. A well-built comparison table drives conversions because it removes the friction of switching between product pages.
The feature is part of Magento Open Source and Adobe Commerce since Magento 2.0. The current release, Magento 2.4.8 (GA April 2025, latest patch 2.4.8-p4 released March 2026), supports PHP 8.3 and 8.4.
Key Features
Versatile Attribute Comparison
Store administrators choose which product attributes appear in the comparison table. You can highlight products with the most attributes, compare by value ranges, or sort by position in the catalog.
Star-Rated Summary
Each product receives a star rating at the bottom of the comparison chart. The rating summarizes results across all compared attributes, giving customers a fast visual indicator.
Customizable Rating System
The module uses a rating distribution system based on attribute values set in the admin panel. Administrators control which attributes factor into the comparison, the criteria for each, and how much weight each attribute carries.
How to Compare Products in Magento
Customers access the comparison feature through four methods:
Method 1: From Catalog Pages
- Browse a catalog or category page.
- Click Add to Compare on each product.
- The Compare Products block appears in the sidebar.
- Click Compare to view the comparison table.
- Use the Delete icon to remove items or Clear All to reset.
Method 2: From Notification Messages
After adding a product to the comparison list, a notification message appears at the top of the page. Click the comparison list link in the notification to go straight to the comparison view.
Method 3: From the Compare Products Block
Click the Compare Products link near the search field in the header. This link appears after you add at least one product to the comparison list.
Method 4: From the My Account Dashboard
Navigate to My Account. The Compare Products block shows all items in your comparison list. Click Compare to open the comparison table.
Comparison List Actions
| Action | Description |
|---|---|
| X | Removes a single item from the comparison list |
| Add to Cart | Adds the product to your cart. Configurable products redirect to the product page first. |
| Wishlist icon | Adds the product to the wishlist (requires wishlist enabled in store configuration) |
| Print This Page | Prints the comparison list |
How to Disable Compare Products in Magento 2
Magento does not include an admin panel switch to disable Compare Products. Here are three methods that work.
Method 1: XML Layout Removal (No Extension Required)
This is the cleanest approach. Create a layout XML file in your theme to remove all compare-related blocks.
File path: app/design/frontend/Your_Vendor/Your_Theme/Magento_Catalog/layout/default.xml
<?xml version="1.0"?>
<page xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="catalog.compare.sidebar" remove="true" />
<referenceBlock name="catalog.compare.link" remove="true" />
<referenceBlock name="category.product.addto.compare" remove="true" />
<referenceBlock name="catalogsearch.product.addto.compare" remove="true" />
<referenceBlock name="view.addto.compare" remove="true" />
<referenceBlock name="related.product.addto.compare" remove="true" />
<referenceBlock name="upsell.product.addto.compare" remove="true" />
<referenceBlock name="wishlist.product.addto.compare" remove="true" />
</body>
</page>
This removes compare buttons from the sidebar, header, category pages, search results, product pages, related products, upsells, and wishlists.
Next step: Set the $showCompare variable to false in these widget templates:
-
Magento/Catalog/view/frontend/templates/product/widget/new/content/new_grid.phtml -
Magento/Catalog/view/frontend/templates/product/widget/new/content/new_list.phtml
After making changes, clear the cache:
php bin/magento cache:clean
php bin/magento cache:flush
Method 2: Free Extensions (One-Click Disable)
If you prefer no code changes, several free Magento extensions handle this:
| Extension | Source | How It Works |
|---|---|---|
| BSS Commerce | Adobe Marketplace | Toggle in admin: Yes/No to disable compare on all pages |
| CodeDecorator | codedecorator.com | Blocks comparison across all pages without template rewrites |
| Galactic Labs | GitHub (MIT) | Observer-based module with admin config toggle |
Installation example (Composer):
composer require bsscommerce/disable-compare
php bin/magento setup:upgrade
php bin/magento cache:flush
Extensions are the fastest option for store owners without development resources. They work across themes without template modifications.
Method 3: Template Variable Override
For granular control, override the $showCompare variable in specific templates. This lets you disable compare on some pages while keeping it active on others.
Copy the target template to your theme directory and set:
<?php $showCompare = false; ?>
Templates to override:
-
vendor/magento/module-catalog/view/frontend/templates/product/list.phtml -
vendor/magento/module-catalog/view/frontend/templates/product/compare/list.phtml
This method gives you page-level control but requires template maintenance during Magento upgrades.
How to Configure Recently Viewed and Compared Products
The admin panel does offer settings for the "Recently Viewed/Compared" widgets. These control how comparison history displays, not the compare feature itself.
- Go to Stores > Configuration > Catalog > Catalog > Recently Viewed/Compared Products.
- Set Synchronize widget products with backend storage (choose Yes or No).
- Select the scope under Show for Current (website, store, or store view).
- Set Default Recently Viewed Products Count (number of products shown).
- Set Default Recently Compared Products Count.
- Configure Lifetime of products in Recently Viewed Widget (display duration).
- Configure Lifetime of products in Recently Compared Widget.
- Click Save Config.
These settings control widget behavior only. To disable the core Compare Products feature, use one of the three methods above.
Best Practices for Product Comparison Pages
Product Images
- Use high-resolution images from multiple angles.
- Place images next to product data for fast visual scanning.
- Add zoom on hover so customers can examine details.
Product Information
- Display clear, bold titles with brand names.
- Show both the online price and original price to highlight savings.
- Include stock availability and shipping estimates.
Comparison Table Design
- Limit to 4-6 key attributes per comparison (too many rows overwhelm customers).
- Highlight differences between products with color coding or bold text.
- Place the "Add to Cart" button at both the top and bottom of the table.
Pros and Cons of Magento Compare Products
| Pros | Cons |
|---|---|
| Reduces back-and-forth between product pages | No admin toggle to disable |
| Shows attributes, prices, and ratings in one table | Page reloads when adding or removing items |
| "Add to Compare" button on category and product pages | No built-in limit on compared products |
| Print option for offline reference | Not optimized for mobile screens |
| Star-rated summary across all attributes | Text-based Yes/No instead of visual icons |
FAQ
1. Can I disable Magento Compare Products from the admin panel?
No. Magento does not include an admin toggle for the Compare Products feature. Use XML layout removal, a free extension, or template overrides to disable it.
2. Does disabling Compare Products affect SEO?
Disabling the compare feature does not impact SEO. The comparison pages are internal tool pages, not indexed landing pages. Removing unused features can improve page load speed, which benefits Core Web Vitals.
3. Which disable method works best for Magento 2.4.8?
All three methods work with Magento 2.4.8. The XML layout method is the most reliable because it requires no third-party dependencies. Extensions offer convenience. Template overrides offer granular control per page.
4. Is there a limit on how many products customers can compare?
Magento has no default limit on the number of compared products. Customers can add as many products as they want. To set a limit, use a third-party extension or override the comparison controller with custom logic.
5. Will the Compare Products feature slow down my store?
The feature itself adds minimal overhead. The performance impact comes from page reloads when adding or removing items from the comparison list. Stores with full-page caching on managed hosting minimize this impact.
6. How do I re-enable Compare Products after disabling it?
For the XML method, remove or comment out the referenceBlock lines in your layout file. For extensions, toggle the setting back to "No" in the admin. For template overrides, set $showCompare back to true. Clear the cache after any change.
7. Does Compare Products work with custom themes?
Yes. The feature works with any theme that follows Magento's standard layout structure. Custom themes that override catalog templates may need adjustments to the disable methods.
8. Can I customize which attributes appear in the comparison table?
Yes. Go to Stores > Attributes > Product, edit the attribute, and set Comparable on Storefront to Yes or No. Only attributes marked as comparable appear in the comparison table.
Summary
Magento Compare Products helps customers evaluate items side by side using attributes, prices, and ratings. The feature ships enabled by default with no admin toggle to turn it off.
To disable it, use XML layout removal for a clean, dependency-free solution. Use a free extension for one-click convenience. Use template overrides for page-level control.
For stores that keep the feature active, optimize comparison tables with high-quality images, clear attribute labels, and prominent Add to Cart buttons. Fast Magento hosting ensures comparison pages load without delays, even with heavy product catalogs.