WooCommerce: Hide “Showing x-y of z results” @ Shop Page

This is quite an annoying thing in WooCommerce when you have just a few products.

Besides, if you only have 1 product in a given category, the notice “Showing the Single Result” will appear on top of the category page.

So, how do we remove the whole “Showing 1–15 of 178 results” element from the Shop, Category, Tag and product loop? Here’s the fix. enjoy!

The annoying "Showing the single result" in WooCommerce
The annoying “Showing the single result” in WooCommerce. We’ll hide that completely with the snippet below, which hides the “Showing x–y of z results” string too.

PHP Snippet 1: Remove “Showing xyz results” @ WooCommerce Shop

In this case we want to remove “Showing the Single Result” but also the other notice that says “Showing x – x of x results”. Basically, the whole element.

/**
 * @snippet       Remove "Showing x results" - WooCommerce
 * @how-to        Get CustomizeWoo.com FREE
 * @author        Rodolfo Melogli
 * @compatible    WooCommerce 5
 * @donate $9     https://businessbloomer.com/bloomer-armada/
 */
 
remove_action( 'woocommerce_before_shop_loop', 'woocommerce_result_count', 20 );

PHP Snippet 2: Remove “Showing xyz results” in Storefront Theme

/**
 * @snippet       Remove "Showing x results" Storefront Theme - WooCommerce
 * @how-to        Get CustomizeWoo.com FREE
 * @author        Rodolfo Melogli
 * @compatible    WooCommerce 5
 * @donate $9     https://businessbloomer.com/bloomer-armada/
 */
 
add_action( 'init', 'bbloomer_delay_remove_result_count' );
 
function bbloomer_delay_remove_result_count() {
   remove_action( 'woocommerce_after_shop_loop', 'woocommerce_result_count', 20 );
   remove_action( 'woocommerce_before_shop_loop', 'woocommerce_result_count', 20 );
}

Where to add this snippet?

You can place PHP snippets at the bottom of your child theme functions.php file (delete "?>" if you have it there). CSS, on the other hand, goes in your child theme style.css file. Make sure you know what you are doing when editing such files - if you need more guidance, please take a look at my free video tutorial "Where to Place WooCommerce Customization?"

Does this snippet (still) work?

Please let me know in the comments if everything worked as expected. I would be happy to revise the snippet if you report otherwise (please provide screenshots). I have tested this code with Storefront theme, the WooCommerce version listed above and a WordPress-friendly hosting on PHP 7.3.

If you think this code saved you time & money, feel free to join 14,000+ WooCommerce Weekly subscribers for blog post updates or 250+ Business Bloomer supporters for 365 days of WooCommerce benefits. Thank you in advance :)

Need Help with WooCommerce?

Check out these free video tutorials. You can learn how to customize WooCommerce without unnecessary plugins, how to properly configure the WooCommerce plugin settings and even how to master WooCommerce troubleshooting in case of a bug!

Rodolfo Melogli

Business Bloomer Founder

Author, WooCommerce expert and WordCamp speaker, Rodolfo has worked as an independent WooCommerce freelancer since 2011. His goal is to help entrepreneurs and developers overcome their WooCommerce nightmares. Rodolfo loves travelling, chasing tennis & soccer balls and, of course, wood fired oven pizza.

37 thoughts on “WooCommerce: Hide “Showing x-y of z results” @ Shop Page

  1. I am trying to show this counter on the page of Avada theme, but I can’t find how. Is there a way o show the product count on the page?

    1. Hi Milen, thanks so much for your comment! Yes, this is definitely possible, but I’m afraid it’s custom work. If you’d like to get a quote, feel free to contact me here. Thanks a lot for your understanding!

  2. Hello,
    I’m using the Flatsome theme, and this code is not working on this theme. please Help

    1. Hello, thanks so much for your comment! Yes, this is definitely possible, but I’m afraid it’s custom work. If you’d like to get a quote, feel free to contact me here. Thanks a lot for your understanding!

  3. Hi Rodolfo, I added the code and it disappeared from the top, but remained under the product, would you please know how to remove that one too?

    thank you

    1. Hi Peter, this snippet removes the default one (on the top). The bottom one is probably generated by your theme, so you need to remove your custom theme action

  4. Worked great today…thanks again for another excellent tip!

    1. Thank you!

  5. I dont find the file “function.php”. In which directory can i find the file? (Windows 10 Search didnt work for me – dont find anything)

    1. Hey Ron, it’s functions.php – if you need more guidance, please take a look at this video tutorial: https://businessbloomer.com/woocommerce-customization-hangout/. Hope this helps!

  6. Works fine!

  7. perfect!

  8. Buongiorno Rodolfo,

    I can access my WP Twenty Seventeen theme’s CSS by clicking Appearance > Editor but how can I have access to the CSS concerning my WooCommerce plugin ?

    1. To follow up on my previous question, I went to Appearance > Editor, went to the bottom of the right column to Stylesheet (style CSS) and clicked on that.
      It brought me to the top of the Edit Theme. I then inserted your text :
      “/* CSS that Removes All Showing Results */
      p.woocommerce-result-count {
      display: none;
      }
      between the “*/” and the “/*” before the table of contents. It doesn’t work.

      Where should I insert the text ?

      1. Hey Michel, as I said privately, try using https://wordpress.org/plugins/simple-custom-css/ πŸ™‚

  9. Hello,

    do you have any idea how to remove the whole background line where the show results was shown?

    I have managed to remove the text but there is still a background of the whole bar where this info was shown. I want to cut all that space and pull the articles up for that space.

    Hopefully you have understood me.

    Thnx

    1. Hey Marin thanks for your comment! You can do so with a simple line of CSS – hope this helps!

  10. Hi,

    I removed it perfectly and also the sort by… horrible useless idea to implement, without asking the user.

    Another question. Do you know how to replace it with a search option in stead ? Preferably one that updates whats left while the user is typing.

    Take care, kind regards Peter

    1. Nice! Thanks for your feedback Peter πŸ™‚

      For the search, I actually published this a few days ago; just change the hook/position and you should be able to figure that out: https://businessbloomer.com/woocommerce-add-custom-search-bar-headerfooter/

      Let me know πŸ™‚

  11. I’ve added the code to the functions.php file:
    // Removes showing results
    remove_action (‘woocommerce_before_shop_loop’, ‘woocommerce_result_count’, 20);
    >> but without success
    hope you help me
    thank you much

    1. Hey! Thanks for your comment πŸ™‚ It could be that your theme or another plugin are already overriding that function. Do a file search for “woocommerce_resulot_count” string and see if anything is affecting that call πŸ™‚ Hope this helps

  12. Dear Rodolfo,

    When I use the CSS it still appears the scrolling menu in the shop page. Is there any CSS to quit it too?

    Thank you

    1. Hello Nico, thanks for your feedback. Are you talking about removing the default sorting dropdown on the Shop page?

      1. Hello Rodolfo, yes, actually it was that. It didn’t work for me so I managed it with this change:

        From:

        add_action( ‘ux_woocommerce_navigate_products’, ‘woocommerce_result_count’, 20 );
        add_action( ‘ux_woocommerce_navigate_products’, ‘woocommerce_catalog_ordering’, 30 );

        To

        remove_action( ‘ux_woocommerce_navigate_products’, ‘woocommerce_result_count’, 20 );
        remove_action( ‘ux_woocommerce_navigate_products’, ‘woocommerce_catalog_ordering’, 30 );

        1. Good stuff Nicolas, thanks for your feedback!

  13. Thank you for the swift reply Rodolfo! I am currently using the theme Storefront: https://www.woothemes.com/storefront/.

    1. Here you go – I also added this in the article above:

      // Removes showing results in Storefront theme
      remove_action( 'woocommerce_after_shop_loop', 'woocommerce_result_count', 20 );
      remove_action( 'woocommerce_before_shop_loop', 'woocommerce_result_count', 20 );
      
      1. This worked perfectly. Thank you very much Rudolfo for the great help! It is very much appreciated! πŸ™‚

        1. Awesome, you’re welcome!

  14. Hi, and thank you for this :).

    However the β€œShowing the Single Result” text appeared on both top of the page and on the bottom, and this trick only removed it on top of the page. Any advice on how to remove the same text on the bottom aswell?

    Thank you!

    1. Hey Marty thanks for the feedback. Probably your theme adds one more element to the bottom. What theme are you using, or can you tell me the address of your website please? Thank you

  15. Cheers this is great!

    1. You’re welcome Martin!

  16. Thanks! πŸ™‚

Questions? Feedback? Support? Leave your Comment Now!
_____

If you are writing code, please wrap it between shortcodes: [php]code_here[/php]. Failure to complying with this (as well as going off topic, not writing in English, etc.) will result in comment deletion. You should expect a reply in about 2 weeks - this is a popular blog but I need to get paid work done first. Please consider joining BloomerArmada to get blog comment reply priority, ask me 1-to-1 WooCommerce questions and enjoy many more perks. Thank you :)

Your email address will not be published.