How to show more product search results in WooCommerce

If a potential customer is using the search box on your online store, it’s a good sign. Searching an online catalog is a classic buying sign, and making sure the correct products show up as quickly as possible is key to converting a browser into a buyer.

Having category / archive paging in place can help cut down on database load and keep catalog pages neat, but have you ever wondered how to show more search results in WooCommerce? After-all, once someone has searched for a particular product, the last thing they probably want to do is page through results.

Subscribe today!
Get WordPress & WooCommerce tips & tricks in your inbox
Invalid email address
Give it a try. You can unsubscribe at any time.

Here’s how to show more product search results in WooCommerce.

function show_everything_on_search_page( $query ) {
    if ( is_search ) { //If the current page is a search results page, continue
        $query->set( 'posts_per_page', 100 ); //Change the number of posts per page to 100
    }
}
add_filter( 'pre_get_posts', 'show_everything_on_search_page' );

Add this snippet to your functions.php file, snippet, or feature plugin.

Leave a Reply