How to Disable a Payment in WooCommerce
Last updated: July 2026
Quick Answer
Go to WooCommerce > Settings > Payments in your WordPress dashboard, find the gateway you want to turn off (Cash on Delivery, Direct Bank Transfer, Cheque Payments, or a third-party gateway like a card processor), and click the toggle so it goes gray. Save changes. The payment method disappears from checkout for every customer immediately. For conditional rules (hide PayPal for orders under $20, hide COD outside a delivery zone, disable a payment method woocommerce store-wide only for wholesale customers), you will need the plugin or code approach in Step 3.
Prerequisites
- Admin access to your WordPress dashboard
- WooCommerce installed and at least one payment gateway configured, per the setup steps in the official WooCommerce documentation
- A staging site or backup if you plan to edit
functions.php(always test code changes before pushing to production) - FTP or file manager access only if you are adding a code snippet manually
Step 1: Disable a Payment Method Natively (No Plugin Needed)
WooCommerce ships with a built-in switch for every payment gateway you have configured. This is the fastest way to disable payment method woocommerce settings without touching any code. If your store also filters products by attribute, this pairs well with the setup in our guide to WooCommerce filter plugins, since a clean checkout usually starts with a clean catalog.
Step 1.1: Open the Payments Tab
From your dashboard, navigate to WooCommerce > Settings > Payments. You will see a list of every installed gateway: Cash on Delivery, Direct Bank Transfer, Cheque Payments, and any card or wallet processors you have connected.
Step 1.2: Toggle the Gateway Off
Click the toggle switch next to the gateway you want to remove. A green toggle means active; gray means disabled. The change applies to all customers and all products the moment you save.
Step 1.3: Reorder Remaining Methods (Optional)
While you are in this screen, drag the remaining gateways into the order you want them displayed at checkout. Businesses that accept credit cards and e-transfer often push the lower-friction option to the top of the list to nudge conversion.
Step 2: Understand Why You Might Want to Hide (Not Fully Disable) a Method
Fully disabling a gateway removes it for every order, everywhere. Many Canadian store owners actually need something more targeted, hiding woocommerce checkout settings per situation rather than store-wide. Common cases we see at Canada Create:
- Hiding Cash on Delivery for orders shipping outside a local delivery radius
- Removing a card gateway for digital-only products where a lighter-weight processor makes more sense
- Blocking a payment option for guest checkout while keeping it open for logged-in wholesale accounts
- Turning off a gateway temporarily during a processor outage without losing its configuration
If any of these match your situation, skip the toggle and use conditional logic instead, covered in the next step. Canada Create readers running a Canadian storefront often compare this to the platform decision covered in our Shopify vs WooCommerce cost breakdown, since payment flexibility is one of the deciding factors.
Step 3: Hide a Payment Method Conditionally
There are two reliable paths here: a plugin, or a small code snippet using WooCommerce hooks.
Step 3.1: Using a Plugin
A popular WooCommerce conditional payments plugin lets you build rules through a visual interface, no code required. Typical rule types include:
| Condition Type | Example Use Case |
|---|---|
| Cart total | Hide COD for carts over $500 to reduce fraud risk |
| Shipping method | Only show bank transfer for local pickup orders |
| User role | Show a net-30 invoice option only to wholesale accounts |
| Product category | Restrict a financing gateway to big-ticket items only |
| Shipping zone / country | Remove COD for orders outside the GTA |
Install the plugin, activate it, then build your rule set under its settings tab. Rules typically apply instantly without caching issues, but clear any page cache plugin afterward to be safe. For a broader look at conditional gateway logic and Canadian processor fees, see our Canadian payment processor fees guide, which breaks down what each gateway actually costs per transaction.
Step 3.2: Using a Code Snippet
If you would rather avoid another plugin, WooCommerce exposes a filter hook called woocommerce_available_payment_gateways that lets you remove a gateway based on any condition you write in PHP. A basic example that removes Cash on Delivery for carts over $500:
add_filter( 'woocommerce_available_payment_gateways', 'cc_hide_cod_over_threshold' );
function cc_hide_cod_over_threshold( $available_gateways ) {
if ( is_admin() ) {
return $available_gateways;
}
if ( isset( $available_gateways['cod'] ) && WC()->cart->get_cart_contents_total() > 500 ) {
unset( $available_gateways['cod'] );
}
return $available_gateways;
}
Add this to your child theme’s functions.php file or a custom snippets plugin, never directly to a parent theme that gets overwritten on update. Swap out 'cod' for the gateway ID you want to target and adjust the condition to match products, shipping zones, or user roles. You can confirm the correct hook signature and available parameters in the official WooCommerce developer documentation.
Before editing any theme file directly, it’s worth reviewing the basics in our WordPress security fundamentals guide, since a botched edit to a live checkout file can take your store offline at the worst possible moment.
Step 3.3: Test Every Scenario
Place a few test orders that match and do not match your condition. Confirm the gateway disappears exactly when expected and reappears when the condition no longer applies. As we cover at Canada Create, skipping this step is the single biggest cause of “my payment method won’t disappear” support tickets. If your store also processes credit cards directly, cross-check your setup against our WordPress credit card processing plugin comparison to make sure your remaining gateways are still PCI-compliant after the change.
Canada Create clients running stores based in the GTA sometimes ask us to audit their entire checkout flow as part of a broader e-commerce website project in Downtown Toronto, since payment gateway logic is only one piece of a healthy checkout.
Troubleshooting
The payment method still shows after I disabled it
Clear your site cache and any CDN cache (Cloudflare, WP Rocket, etc.). Checkout pages are sometimes cached and will keep showing old gateway lists until the cache clears.
My code snippet isn’t hiding the gateway
Double check the gateway ID. Go to WooCommerce > Settings > Payments, click into the gateway, and check the URL or the gateway’s settings page for its exact ID string (for example cod, bacs, cheque).
A plugin conflict is hiding all gateways
Deactivate other checkout-related plugins one at a time to isolate the conflict. Gateway visibility logic from two different plugins can sometimes cancel each other out.
Customers report the gateway reappearing on mobile
This is almost always a caching issue tied to a mobile-specific cache rule. Check whether your host or CDN caches mobile and desktop views separately. According to guidance from the Government of Canada’s business payments resources, Canadian merchants should also confirm their remaining gateways meet current consumer protection disclosure requirements after removing an option.
Frequently Asked Questions
How do I disable a payment method in WooCommerce?
Go to WooCommerce > Settings > Payments and toggle the gateway off. This removes it from checkout for all customers immediately, with no code required.
Can I hide a payment method for specific products in WooCommerce?
Yes. Use a conditional payments plugin or the woocommerce_available_payment_gateways filter hook to remove a gateway when a specific product or category is in the cart.
How do I hide Cash on Delivery in WooCommerce for certain orders?
Add a condition based on cart total, shipping zone, or shipping method using a plugin or a code snippet, so COD only appears when your criteria are met.
Why is my WooCommerce payment method still showing after I disabled it?
The most common cause is a cache serving an old version of the checkout page. Clear your site cache, plugin cache, and any CDN cache, then reload checkout in a private browser window.
Do I need a plugin to disable WooCommerce payment gateways?
No. Store-wide disabling only needs the native toggle in WooCommerce Settings. A plugin or code snippet is only necessary for conditional, rule-based hiding.

