How to remove "My Wish List" and "Compare Products" blocks from Magento 2.0 Luma template?

I've tried following step it worked for me.

1. My Wish List

For wish List you need to remove it via Admin > Stores > Configuration > Customers > Wish list > General Options make to enabled to no and then save it.

2. Compare Product

Here you need to do some coding level changes. follow me

Go to vendor > magento > theme-frontend-luma > Magento_Catalog > layout > default.xml

Open this file find this tag "" and before body end tag put the following code

<referenceBlock name="catalog.compare.sidebar" remove="true"/>

Make sure this will remove compare product from category product listing however you can uses this to any layout.

Once you done with this don't forget to clearing cache if enable otherwise you will not get desirable output.

Let me know if you have still any query


Magento 2.2.3 - Get rid of the compare

So I had the same issue, but found out I needed to add a way more to the default.xml to get rid of the compare:

<referenceBlock name="catalog.compare.sidebar" remove="true"/> <!-- Remove sidebar -->
<referenceBlock name="catalog.compare.link" remove="true"/> <!-- Remove link in header -->
<referenceBlock name="related.product.addto.compare" remove="true"/> <!-- Related product -->
<referenceBlock name="category.product.addto.compare" remove="true"/> <!-- Category add compare -->
<referenceBlock name="view.addto.compare" remove="true" /> <!-- Product addto compare -->

instead to remove parent block just remove to the point block

<referenceBlock name="catalog.compare.sidebar" remove="true"/>
<referenceBlock name="wishlist_sidebar" remove="true"/>