WooCommerce product pages are packed with useful information for your customers, displayed through various tabs such as Description, Reviews, and Additional Information. However, depending on your store’s needs, you might find some of these tabs unnecessary or want to remove them entirely. In this blog post, we’ll explore different ways to remove tabs from WooCommerce single product pages, both using a plugin and via code snippets.
Why Remove a Tab?
You might want to remove a WooCommerce tab if:
- You don’t need the Additional Information tab (e.g., if your products don’t have attributes or dimensions).
- You prefer to show product reviews elsewhere on the page, making the Reviews tab redundant.
- You want a cleaner, more streamlined product page that eliminates unnecessary information.
No matter the reason, WooCommerce makes it simple to manage tabs with plugins or code.
Option 1: Removing Tabs Using a Plugin
If you’re not comfortable editing code, using a plugin is the easiest way to remove tabs from your WooCommerce product pages.
Recommended Plugin: WooCommerce Tab Manager
WooCommerce Tab Manager is a powerful premium plugin that allows you to remove, add, and reorder tabs on your product pages without touching any code.
Steps to Remove a Tab Using WooCommerce Tab Manager:
- Install and activate the plugin: Head over to the WooCommerce marketplace or your WordPress admin panel, search for the WooCommerce Tab Manager plugin, and install it.
- Go to the Tab Manager settings: Navigate to WooCommerce > Tab Manager in your WordPress dashboard.
- Customize tabs: You’ll see a list of all default WooCommerce tabs. From here, you can easily remove any tab (e.g., Description, Reviews, or Additional Information) by disabling it.
- Save Changes: Once you’ve removed the unwanted tabs, click Save, and those tabs will no longer appear on your product pages.
This plugin offers a straightforward interface to manage all your tabs, making it an excellent solution for users who prefer a no-code approach.
Option 2: Removing Tabs Using Code Snippets
For users who want more control or don’t wish to use a plugin, WooCommerce allows you to remove tabs by adding a few lines of code to your theme’s functions.php
file. Below are the code snippets you can use to remove individual tabs.
How to Remove the Description Tab
The Description tab is one of the default tabs in WooCommerce. To remove it, follow these steps:
- Go to Appearance > Theme File Editor in your WordPress dashboard.
- Edit your theme’s
functions.php
file (preferably in a child theme to avoid losing changes during theme updates). - Add the following code to remove the Description tab:
// Remove the Description tab
add_filter( 'woocommerce_product_tabs', 'remove_description_tab', 98 );
function remove_description_tab( $tabs ) {
unset( $tabs['description'] ); // Remove the description tab
return $tabs;
}
This code removes the Description tab from all WooCommerce product pages.
How to Remove the Reviews Tab
If you don’t need the Reviews tab, you can remove it using a similar process. Add the following code to your theme’s functions.php
file:
// Remove the Reviews tab
add_filter( 'woocommerce_product_tabs', 'remove_reviews_tab', 98 );
function remove_reviews_tab( $tabs ) {
unset( $tabs['reviews'] ); // Remove the reviews tab
return $tabs;
}
This will disable the Reviews tab globally across all products.
How to Remove the Additional Information Tab
The Additional Information tab usually displays technical details about the product, such as attributes or dimensions. If your products don’t use these fields, you can remove this tab with the following code:
// Remove the Additional Information tab
add_filter( 'woocommerce_product_tabs', 'remove_additional_info_tab', 98 );
function remove_additional_info_tab( $tabs ) {
unset( $tabs['additional_information'] ); // Remove the additional information tab
return $tabs;
}
This code removes the Additional Information tab across all products.
Remove Multiple Tabs at Once
If you want to remove more than one tab, you can combine the snippets into a single function. For example, to remove the Description, Reviews, and Additional Information tabs simultaneously, use this combined snippet:
// Remove multiple WooCommerce tabs
add_filter( 'woocommerce_product_tabs', 'remove_multiple_tabs', 98 );
function remove_multiple_tabs( $tabs ) {
unset( $tabs['description'] ); // Remove the description tab
unset( $tabs['reviews'] ); // Remove the reviews tab
unset( $tabs['additional_information'] ); // Remove the additional information tab
return $tabs;
}
This method is efficient and keeps your functions.php
file tidy.
Conclusion
Customizing the WooCommerce product page by removing unnecessary tabs can help improve user experience and streamline your product pages. Whether you opt for a plugin or prefer using code snippets, WooCommerce provides flexible ways to manage tabs.
Quick Summary:
- For non-coders: The WooCommerce Tab Manager plugin provides an easy way to manage, add, or remove tabs with a user-friendly interface.
- For developers: You can remove specific tabs like Description, Reviews, or Additional Information by adding simple code snippets to your theme’s
functions.php
file.
With these methods, you’ll have full control over the appearance of your WooCommerce product pages, creating a more tailored shopping experience for your customers.
If you need help customising your WooCommerce store get in touch.
Photo by Andrew Pons on Unsplash