Skip to content
Arrow keys to move, Enter to open, Esc to closeAll results
E-commerce · Guides

How to Set Up Stripe Payments in WordPress

Three ways to accept cards with Stripe on a WordPress site, how to test safely, and the settings that prevent failed payments.

Written by
WPresident Editorial
Updated
November 2026
Topic
E-commerce

Stripe is a payment processor that lets you accept cards and many local payment methods online. On WordPress there are several ways to connect it, and the right one depends on what you sell. This guide covers the options, a safe setup and a testing routine.

The Stripe website
Stripe, the payments platform: stripe.com.

Which method fits your site?

You sell Good option
Products in a WooCommerce store The Stripe payment gateway for WooCommerce, or another gateway plugin that supports Stripe.
Digital products, subscriptions or memberships A store or membership plugin with a built-in Stripe integration.
A few items or donations on a simple site Stripe Payment Links or hosted Checkout, linked from a button.
Invoices and custom amounts Stripe Invoicing, or a form plugin that supports Stripe payments.

Set up Stripe with WooCommerce

  1. Create a Stripe account and complete business verification.
  2. Install the Stripe gateway plugin for WooCommerce and activate it.
  3. In WooCommerce, Settings, Payments, open Stripe and connect your account. Prefer the plugin’s connect flow over pasting keys by hand.
  4. Choose your payment methods and enable the payment request buttons you want.
  5. Add the webhook address the plugin shows you in the Stripe dashboard so order status updates reliably.

Test before you take real money

  • Switch the gateway to test mode and use Stripe’s test card numbers, for example 4242 4242 4242 4242 with any future expiry and any security code.
  • Test a successful payment, a declined card and a payment that needs authentication.
  • Confirm the order status changes, the customer email arrives and the payment appears in the Stripe dashboard.
  • Switch to live mode and place one small real order, then refund it.

Security and compliance basics

  • Use HTTPS across the whole site. Stripe requires it for live payments.
  • Let Stripe handle card data. Official integrations use hosted fields, so card numbers never touch your server. That keeps your compliance burden small.
  • Protect the keys. Treat secret keys like passwords. Never put them in theme files or public repositories.
  • Restrict API keys where Stripe allows it, and rotate them if you suspect exposure.

Common problems and fixes

  • Orders stuck on “pending payment”: the webhook is missing or blocked. Re-add it and check your firewall.
  • Payments declined for no clear reason: fraud settings or bank checks. Check the payment’s details in Stripe.
  • Test mode left on: check the gateway setting after launch.
  • Cached checkout: exclude cart and checkout from page caching.

Final thoughts

Stripe is straightforward on WordPress when you use an official or well-maintained integration. Test every path, protect your keys and confirm that webhooks work before you advertise the store.

Frequently asked questions

Does Stripe work with any WordPress theme?

Yes. The payment integration lives in a plugin, not the theme. Make sure your checkout page layout is compatible with the plugin.

Is Stripe free?

There is no monthly fee for standard accounts, but Stripe charges a per-transaction fee that depends on your country and payment method. Check Stripe's pricing page for current rates.

W
Written byWPresident EditorialThe WPresident editorial team. We test products on real sites, score them with one public method and write up what holds up.

Keep reading

E-commerce

The Best WooCommerce Plugins in 2026

A WooCommerce toolbox sorted by job: subscriptions, card processing, checkout, product options, search and wishlists, with the real cost of each and a rule for a small stack.

Read more
WPresident EditorialNovember 2026

Get the Monthly Launch Report

One email a month: the best of last month's articles, new reviews and what changed in WordPress, without the noise.

No spam. Unsubscribe in one click.

Signed and sealed,
The WPresident

Press Esc to close. Use the arrow keys to move through results.