Connect Stripe to WooCommerce: A Complete Guide

Connect Stripe to WooCommerce: A Complete Guide

Connect Stripe to WooCommerce: A Complete Guide

1. Install and Activate the WooCommerce Stripe Gateway Plugin

1.1. Access Your WordPress Dashboard

Log in to your WordPress administrative area. You can typically do this by navigating to yourdomain.com/wp-admin in your web browser. Enter your username and password in the provided fields and click “Log In.”

1.2. Navigate to Plugins and Add New

Once logged in, locate the “Plugins” menu item on the left-hand sidebar of your dashboard. Click on “Plugins” to expand the submenu, then click on “Add New.” In the search bar on the “Add Plugins” page, type “WooCommerce Stripe Gateway” and press Enter. Look for the plugin developed by WooCommerce (Automattic) and click “Install Now.” After the installation is complete, click “Activate” to enable the plugin on your site.

2. Configure Your Stripe API Keys

2.1. Retrieve Your Stripe API Keys

Open a new browser tab and log in to your Stripe account at dashboard.stripe.com. From your Stripe dashboard, navigate to “Developers” in the left-hand menu, then click on “API keys.” You will see two sets of keys: “Publishable key” and “Secret key.” For the secret key, you may need to click “Reveal test key” or “Reveal live key” depending on whether you are setting up for testing or live transactions. Copy both the Publishable key and the Secret key for the mode you intend to use (e.g., live keys for live transactions).

2.2. Enter API Keys into WooCommerce

Return to your WordPress dashboard. Navigate to “WooCommerce” > “Settings” from the left-hand menu. Click on the “Payments” tab at the top of the settings page. Scroll down until you find “Stripe” or “Stripe – Credit Card.” Click on “Manage” next to the Stripe option. On this page, you will see fields for “Publishable key” and “Secret key.” Paste the respective keys you copied from your Stripe dashboard into these fields. Ensure you are pasting the live keys if you intend to go live immediately, or test keys if you are still in development. Click “Save changes” at the bottom of the page.

3. Set Up Stripe Payment Methods in WooCommerce

3.1. Enable Stripe Payment Gateways

On the same “WooCommerce” > “Settings” > “Payments” page, ensure that the main “Stripe” gateway is enabled by toggling the switch next to it to the “On” position. Depending on the Stripe plugin version and your regional settings, you might also see other Stripe-powered payment methods listed, such as “Stripe – Apple Pay / Google Pay,” “Stripe – SEPA Direct Debit,” etc. Enable any of these additional methods that you wish to offer your customers by toggling their respective switches to “On.”

3.2. Customize Payment Gateway Settings

For each enabled Stripe payment method, click on the “Manage” button next to it. Here you can configure specific settings. For the main “Stripe – Credit Card” gateway, you can set a “Title” (e.g., “Credit Card (Stripe)”), a “Description” (e.g., “Pay securely with your credit or debit card via Stripe.”), and optionally enable features like “Payment Request Buttons” (for Apple Pay/Google Pay on product/cart pages) or “Save cards” (allowing customers to save their card details for future purchases). Make sure “Enable Test Mode” is unchecked if you are configuring for live transactions. For other methods like SEPA, you might need to configure additional details or ensure your Stripe account supports them. Click “Save changes” after modifying each gateway’s settings.

4. Test and Go Live with Your Stripe Integration

4.1. Conduct Test Transactions

Before going live, it is crucial to perform test transactions to ensure everything is working correctly. First, go back to “WooCommerce” > “Settings” > “Payments” > “Stripe – Credit Card” and ensure “Enable Test Mode” is checked. Use your Stripe test API keys (which are different from your live keys) in the settings. Open your website in a private or incognito browser window, add a product to your cart, and proceed to checkout. Use Stripe’s test card numbers (e.g., 4242 4242 4242 4242 for a successful charge) along with any future expiry date and a CVC of 123. Complete the order. Then, log into your Stripe dashboard and check your “Developers” > “Logs” and “Payments” sections to confirm the test transaction was received successfully. Also, verify that the order status in your WooCommerce “Orders” section reflects the successful payment.

4.2. Disable Test Mode and Go Live

Once you are confident that your test transactions are processing correctly, it’s time to switch to live mode. Return to “WooCommerce” > “Settings” > “Payments” > “Stripe – Credit Card” in your WordPress dashboard. Uncheck the “Enable Test Mode” checkbox. Crucially, replace your test API keys with your *live* Publishable Key and Secret Key that you retrieved from your Stripe dashboard earlier. Click “Save changes.” Your Stripe integration is now live and ready to accept real customer payments. It’s a good practice to perform one small live transaction yourself (e.g., purchase a low-cost product) to confirm the live setup is fully functional.

FAQ 1: My Stripe payment option isn’t showing up at checkout. What should I do?

First, ensure the “WooCommerce Stripe Gateway” plugin is installed and activated under “Plugins.” Second, go to “WooCommerce” > “Settings” > “Payments” and verify that the “Stripe – Credit Card” gateway has its toggle switch set to “On.” Also, check the “Manage” settings for Stripe to ensure your API keys are correctly entered and there are no error messages displayed. Finally, clear any caching plugins on your WordPress site, as they can sometimes prevent changes from appearing immediately.

FAQ 2: Do I need an SSL certificate for Stripe to work?

Yes, an SSL certificate is absolutely mandatory for accepting payments with Stripe. Stripe requires that all payment information is transmitted over a secure HTTPS connection. If your website does not have an SSL certificate installed and properly configured (meaning your URL starts with https:// instead of http://), Stripe will not function, and your customers will likely see security warnings or be unable to complete their purchases. Most hosting providers offer free SSL certificates (e.g., Let’s Encrypt) or premium options.

FAQ 3: How do I handle refunds through WooCommerce with Stripe?

Once a payment has been processed via Stripe through your WooCommerce store, you can issue refunds directly from your WooCommerce order management screen. Go to “WooCommerce” > “Orders,” click on the specific order you wish to refund. In the “Order details” section, scroll down to the “Items” box. Below the items, click the “Refund” button. Enter the quantity or amount to refund for each item, and then click “Refund via Stripe.” This will process the refund through your Stripe account, and the funds will be returned to the customer’s original payment method. Note that Stripe may have transaction fees that are not refunded.

FAQ 4: Can I use Stripe for subscriptions or recurring payments in WooCommerce?

Yes, the WooCommerce Stripe Gateway plugin fully supports recurring payments, but it requires an additional premium plugin: “WooCommerce Subscriptions.” Once you have both the WooCommerce Stripe Gateway and WooCommerce Subscriptions plugins installed and activated, you can create subscription products in WooCommerce. When customers purchase these subscription products and pay via Stripe, the Stripe plugin will handle the recurring charges automatically based on the subscription schedule defined in WooCommerce Subscriptions.

Scroll to Top