Selling with Stripe

Updated

Turn on Stripe to let buyers pay by card. Buyers pay on Stripe’s own page and come back to a receipt on your site.

Your site never sees card numbers; it only learns whether the payment went through. Only administrators can open LMS → Payments.

Set up Stripe

  1. Go to LMS → Payments and find the Stripe card.
  2. Turn on Accept card payments with Stripe.
  3. Leave Mode on Test: no real money moves while you try it out. Only the keys for the chosen mode are shown.
  4. Copy the secret key from the Stripe Dashboard, Developers → API keys, into Test secret key.
  5. Press Save on the card. Once Stripe is on, the card shows a Webhook address.
  6. Add the Webhook address as a webhook endpoint in the Stripe Dashboard, copy the endpoint’s signing secret into Test webhook signing secret, and press Save again.

The card’s header says Taking payments when buyers can use Stripe, or Off.

The fields

FieldWhat it does
Accept card payments with StripeTurns the method on.
Name at checkoutWhat buyers see. The default is “Card”.
ModeTest: no real money moves (the default) or Live. Only the keys for the chosen mode are shown.
Test secret key, Live secret keyFrom the Stripe Dashboard, Developers → API keys. Test keys start with sk_test_ or rk_test_, live keys with sk_live_ or rk_live_.
Test webhook signing secret, Live webhook signing secretThe signing secret of the webhook endpoint for that mode. It starts with whsec_.

Keys are stored encrypted and never shown again. A saved key shows as “Saved (…). Type to replace.” and has a Remove saved key link.

The webhook

The webhook lets payments and refunds made in Stripe reach your site even if a buyer closes the tab before returning. The plugin listens for completed, failed and expired checkout sessions and for refunds.

Add the Webhook address in the Stripe Dashboard once in test mode and once in live mode. Each endpoint has its own signing secret; copy it into the matching field.

Test mode and going live

Test mode takes no real money

While Stripe or PayPal is in test or sandbox mode, the checkout shows a Test mode label next to it, and orders paid that way are marked as test payments on LMS → Orders. No real money moves. Switch Mode to Live when you are ready to take real money.

To go live:

  1. Set Mode to Live.
  2. Enter the Live secret key.
  3. Add the Webhook address as an endpoint in the Stripe Dashboard in live mode and copy its signing secret into Live webhook signing secret.
  4. Press Save on the card.

What is sent to Stripe

The plugin contacts Stripe only once you turn it on and enter its keys. When a buyer places an order and chooses Stripe, the plugin sends Stripe the order number, the course names and prices, the currency, the buyer’s email address and the addresses to return to. Refunds made on LMS → Orders send Stripe the payment’s reference and the amount. See External services.

Next: Cart and checkout and Orders and refunds.

Was this page helpful?