All posts

WooCommerce test mode: how to test the checkout without real payments

WooCommerce has no switch that puts the whole store in test mode. Each payment gateway has its own, and some have none. Which method suits you depends on what you want to prove: that the card form works, or that a buyer on the live store can get from cart to order confirmation right now.

Free checkout scan

Enter your store address. A real browser adds a product to the cart and walks the checkout up to the payment step, like a customer, and shows you every step with a screenshot.

  • Free, no account
  • Stops before payment, no order
  • Nothing to install
· 3 min read
Paying with a card on a laptop checkout

What each method tests

MethodTests the live storeTests the card formSide effects
Gateway test modeYes, but real buyers can’t pay while it is onYesTest orders in the order list
Staging copyNoYes, with test keysNone on live
Offline method (cash on delivery, bank transfer)YesNoA real order: stock, emails, exports
100% coupon (zero total)YesNoA real order, no payment step
Outside check that places and cancels a test orderYesNoOne cancelled order per run
Gateway test modecard form · blocks real cards while onStaging copysafe · different cache, CDN, firewallOffline method / 100% couponlive store · a real order to cancelScheduled outside checklive store · places and cancels, every run
Only tests on the live store prove a buyer can order right now. Gateway test modes and staging prove the card form and your changes.

Gateway test modes

WooPayments: Payments → Settings → enable test mode. Pay with Stripe’s test card 4242 4242 4242 4242, any future date and any CVC.

Stripe for WooCommerce: WooCommerce → Settings → Payments → Stripe → enable test mode and paste the test keys from the Stripe dashboard.

PayPal Payments: connect a PayPal sandbox account in the plugin settings and pay with a sandbox buyer.

Not on a store that sells

A gateway in test mode on the live store refuses real cards. Use it on staging, or for a few minutes when no one is buying, and switch it back straight away.

Staging and offline methods

A staging copy is the safe place for gateway test modes, plugin updates and theme changes. It does not prove the live store works: cache, CDN, firewall and DNS are usually different there.

An offline method such as cash on delivery or direct bank transfer places a real order on the live store without charging anyone. If you do not offer one to buyers, a small snippet or plugin can show it to administrators only. The order is real: it reduces stock, sends emails and may reach your ERP or invoicing, so cancel it afterwards. WooCommerce puts the stock back when an order is cancelled.

php
// Cash on delivery for shop managers only
add_filter( 'woocommerce_available_payment_gateways', function ( $gateways ) {
    if ( is_admin() ) {
        return $gateways;
    }
    if ( ! current_user_can( 'manage_woocommerce' ) ) {
        unset( $gateways['cod'] );
    }
    return $gateways;
} );
In a small plugin or Code Snippets; enable Cash on delivery first

A 100% coupon brings the total to zero, and WooCommerce then skips the payment step. It proves the cart, shipping and order creation work, but not the payment form.

Testing the live checkout on a schedule

Every method above is a test someone has to remember to run. Most broken checkouts appear between those tests, after a plugin update, a cache change or a gateway outage.

MageSentinel walks the live WooCommerce checkout as a guest in a real browser on a schedule: product, cart, checkout, shipping and payment. With the MageSentinel plugin connected and "Place a real order" on, it places the order with an offline method and the plugin cancels it afterwards. The plugin only cancels its own orders: a magesentinel+… address, under an hour old and unpaid. Real test orders are on paid plans; the free WooCommerce checkout checker walks your checkout once without signing up.

For a list of what to look at on each test, see why the WooCommerce checkout stops working, and after a release, testing the checkout after a deployment.

Find out your checkout broke before your customers do.

Real checkout checks for Magento and WooCommerce · free plan · no card requiredWooCommerce checkout monitoring →
FAQ

Common questions

Still have a question?More answers, and a way to reach us.Support →
01Does WooCommerce have a test mode?

Not for the whole store. Each payment gateway has its own test or sandbox mode, such as WooPayments test mode, Stripe test keys or a PayPal sandbox.

02How do I place a test order in WooCommerce without paying?

Use an offline method such as cash on delivery or bank transfer, or a 100% coupon that brings the total to zero, then cancel the order so stock is restored.

03Can I leave Stripe in test mode on my live store?

No. While test mode is on, real cards are refused. Use it on staging or switch it back right after testing.