WooCommerce, by default, will always display a notice that a product is on sale if you set a discounted price in the product settings.
But what if you don’t want those sale banners to be displayed even if you have discounted products?
Nothing, nothing happens, it’s just another choice, which with WooCommerce is very easy to achieve.
Just add the following code to the functions.php file of your active theme (child theme, remember) or to a customization plugin if you have one:
/* Hide sale button */
add_filter( 'woocommerce_sale_flash', 'wphelp_hide_sale' );
function wphelp_hide_sale( $sale_badge ){
return '';
}
Code language: PHP (php)
Save the changes and the buttons, banners, offer messages or whatever you call them, will disappear from both the product detail page and the product catalog of the store.
