Removing the add to cart button from specific product pages

I think you can update the condition of your function remove_add_cart_button to check for products, something like the code below: /** * Remove add to cart button */ function remove_add_cart_button(){ // Products $product_ids = array(110, 111, 112); //todo: put your product ids here if(in_array(get_the_ID(), $product_ids)){ remove_action(‘woocommerce_single_variation’, ‘woocommerce_single_variation_add_to_cart_button’, 20); } }