Remove Coupon Field on the Checkout Page for Guest Users in WooCommerce

Remove coupon field on the checkout page for guest users if using WooCommerce on your child site.

Snippet Type

Execute on Child Sites


function no_coupon_checkout_function() {
    if ( !is_user_logged_in() ) {

    remove_action( 'woocommerce_before_checkout_form', 'woocommerce_checkout_coupon_form', 10 );

add_action('init', 'no_coupon_checkout_function');

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.