Search
Close this search box.

How to remove tabs in WooCommerce

To remove WooCommerce tabs in WordPress using the functions.php file, you can use the woocommerce_product_tabs filter hook. This hook allows you to modify the tabs that are displayed on product pages in WooCommerce.

Here is an example of how you can use this hook to remove the “Description” and “Reviews” tabs from product pages:

// Remove tabs in WooCommerce
// More snippets at wpunplugged.com 

function remove_woocommerce_tabs( $tabs ) {
    unset( $tabs['description'] ); // Remove the description tab
    unset( $tabs['reviews'] ); // Remove the reviews tab
    return $tabs;
}
add_filter( 'woocommerce_product_tabs', 'remove_woocommerce_tabs', 98 );

In this example, we are using the unset() function to remove the “Description” and “Reviews” tabs from the array of tabs that are passed to the hook. You can use this same approach to remove any other tabs that you don’t want to display on your product pages.

It’s important to note that this code will only remove the tabs from the front-end of your site. If you want to remove the tabs from the back-end as well, you will need to use a plugin or additional code to do so.

Share this post

You might also like...

Pre-built websites in BeTheme
Themes

Betheme for WordPress Review

Betheme is a WordPress theme that has been described as one of the most powerful and versatile themes available for WordPress. In this Betheme for

Read More »
WooCommerce for WordPress Review
Ecommerce

WooCommerce for WordPress Review

WooCommerce for WordPress is a great choice for anyone looking to create an online store. Its user-friendly interface makes setup and customization simple, while its

Read More »

Comment

Your email address will not be published. Required fields are marked *