Ready to get started?Download WordPress


WooCommerce - excelling eCommerce
Remove prices from Widget/Sidebar listings (6 posts)

  1. Rican UK
    Posted 9 months ago #


    I was just wondering if its possible to remove the product prices from products listed in the sidebar, eg 'Best Sellers'.

    Thanks in advance...



  2. DeeperLook
    Posted 7 months ago #

    I'm wondering the same thing?

  3. esmi
    Forum Moderator
    Posted 7 months ago #

    @DeeperLook: If you require assistance then, as per the Forum Welcome, please post your own topic.

  4. DeeperLook
    Posted 7 months ago #

    Hey Rican,

    I found it, go to /woocommerce/classes/widgets/ and select the widgets you wish to change.

    From there find this line of code and remove it:
    ' . $product->get_price_html() . '

    Now save and you're done. Hope this helps.


  5. Rican UK
    Posted 7 months ago #

    Hi DeeperLook,

    What will happen when I update Woocommerce? These files are likely to be replaced with the original removing my changes. Is there anyway I can copy them to my child theme so they are not replaced?

    Also, I really only want to remove the price if users are not logged in. Currently I have some code which replaces all prices with 'Login or Register to see price' if the user isn't logged in. This works fine for the main product price, but looks very messy on the best sellers list!

    If there was some code amendments I could make that only removes the price for logged out users, that would be great!

    Many thanks for this code anyway....


  6. MastroPino
    Posted 5 months ago #

    Thanks mate, simple and fast!


You must log in to post.

About this Plugin

About this Topic