Friday , February 7 2025

How to remove unused tabs for product editing in WordPress admin panel

By default, the product edit page has several tabs that are never used for simple stores. In this article, the code you need to put in functions.php in your theme folder. In this example, the Deliveries tab is removed, but you can uncomment any line and the tab that you do not want to see in the admin panel will be removed.

function remove_tab_woo_custom($tabs){
    //unset($tabs['general']); // Delete the General tab
    //unset($tabs['inventory']); // Delete the Stocks tab
    //unset($tabs['advanced']); // Delete the Advanced tab
    //unset($tabs['linked_product']); // Delete the Related Products tab
    unset($tabs['shipping']); // Delete the Deliveries tab
    //unset($tabs['attribute']); // Delete the Attributes tab
    //unset($tabs['variations']); // Delete the Variations tab
    return($tabs);
}
add_filter('woocommerce_product_data_tabs', 'remove_tab_woo_custom', 10, 1);

About iryna

I'm Iryna, a web developer from Ukraine with a decade of experience solving complex technical challenges in the world of freelance. Throughout my career, I've worked on everything from troubleshooting server-side issues and optimizing website performance to enhancing user interfaces. On this blog, I share detailed solutions to the technical problems I’ve encountered and methods that have worked best for me. In addition to my technical expertise, I’m also passionate about digital drawing. I hope the tutorials and insights I provide here will help both fellow developers and creatives alike in their own projects.

Check Also

How to remove 404 //fonts.gstatic.com and //fonts.googleapis.com from WordPress head section

I tried solutions with functions that should remove from head and , but a very …

Leave a Reply

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