Disable email field on WooCommerce customer account details

Is there a possibility to disable the email field on WooCommerce customer account details? Or Is there a hook or action available to do such thing? I’m just using a pre-made themes and not that much into PHP. Have tried this plugin called “Prevent Email Change” by Happy Plugins, but it didn’t worked.

Would really appreciate any help from this.

Thanks,

3 Answers
3

You can do it by adding this code to functions.php:

function custom_override_checkout_fields( $fields ) {
    unset($fields['billing']['billing_email']);    
    return $fields;
}
add_filter( 'woocommerce_checkout_fields' , 'custom_override_checkout_fields', 1000, 1 );

But it is wrong approach, since WooCommerce uses email to notify user about status of the order.

Leave a Comment