Setting Up Stripe for WooCommerce in 2018: A Beginner’s Guide
So, you’ve decided to sell online using WooCommerce, and you’re smart enough to integrate with Stripe! Excellent choice. Stripe is a powerhouse when it comes to online payments, offering a secure and reliable way to accept credit cards, debit cards, and other payment methods directly on your website. This guide will walk you through setting up Stripe with WooCommerce in 2018 (the principles are still largely valid today!), even if you’re a complete newbie.
Why Stripe? Why Now (or Any Time)?
Before we dive in, let’s briefly touch on why Stripe is such a popular choice for WooCommerce users:
* Direct Payments: Customers can pay directly on your site, without being redirected to a third-party payment gateway like PayPal. This creates a smoother, more professional experience.
* Security: Stripe handles sensitive payment information using top-notch encryption and security measures, so you don’t have to worry about storing credit card details yourself.
* Customization: Stripe allows for a high degree of customization, allowing you to create a payment process that perfectly matches your brand.
* Pricing: Stripe’s pricing is transparent and competitive, usually a per-transaction fee.
* Widely Used: Stripe is a well-established payment processor with a strong reputation and plenty of documentation.
Think of it this way: Imagine you’re opening a physical store. Stripe is like having your own private credit card terminal that connects directly to the bank, rather than relying on a separate service (like an ATM in the corner of the shop) to handle the transactions. This direct connection gives you more control and a cleaner customer experience.
Prerequisites
Before you start, make sure you have the following:
* A WooCommerce-powered website: You need a working WooCommerce store. If you don’t have one, you’ll need to install and configure WordPress and WooCommerce first.
* A Stripe Account: If you don’t have a Stripe account, you’ll need to create one at [https://stripe.com/](https://stripe.com/). It’s free to sign up, and you only pay transaction fees when you make a sale.
* A Secure Website (HTTPS): This is critical! You need an SSL certificate for your website to securely transmit payment information. Most hosting providers offer free SSL certificates (e.g., Let’s Encrypt). Look for the padlock icon in your browser’s address bar.
Step-by-Step Installation and Configuration
Let’s get down to business! Here’s how to integrate Stripe with WooCommerce:
Step 1: Install the WooCommerce Stripe Plugin
1. Log in to your WordPress admin panel.
2. Go to Plugins > Add New.
3. Search for “WooCommerce Stripe Payment Gateway“.
4. Look for the plugin created by WooCommerce (or Stripe directly – both are reputable). It should have a high rating and a large number of active installations.
5. Click Install Now.
6. After installation, click Activate.
Step 2: Configure the Stripe Plugin
1. Go to WooCommerce > Settings > Payments.
2. You should see Stripe – Credit Card (Stripe) as an available payment method.
3. Click the Manage button next to “Stripe – Credit Card (Stripe)”. This will take you to the Stripe settings page.
Step 3: Connect to Stripe (API Keys)
This is where you’ll connect your WooCommerce store to your Stripe account using API keys. You’ll need to find these keys in your Stripe dashboard.
1. Log in to your Stripe dashboard at [https://dashboard.stripe.com/](https://dashboard.stripe.com/).
2. Go to Developers > API Keys.
3. You’ll see two sets of keys: Publishable Key and Secret Key.
* Important: Keep your Secret Key safe! Do not share it with anyone. It’s like the password to your Stripe account.
4. In your WooCommerce Stripe settings:
* Check the “Enable Stripe” box to activate the payment gateway.
* Optionally, change the title and description that customers will see during checkout. For example:
* Title: “Credit Card (Stripe)” or “Pay with Credit Card”
* Description: “Pay securely using your credit or debit card through Stripe.”
* Set the Test mode option to “Enable Test Mode” to try your gateway without real money.
* Copy your Publishable Key (Test) from your Stripe dashboard and paste it into the “Test Publishable Key” field in WooCommerce.
* Copy your Secret Key (Test) from your Stripe dashboard and paste it into the “Test Secret Key” field in WooCommerce.
* Once you are ready for live transactions, uncheck Enable Test Mode and copy your Publishable Key (Live) and Secret Key (Live) from your Stripe dashboard and paste it into the appropriate fields.
* Set the Webhook endpoint in your stripe dashboard in “Developers > Webhooks”. This can be found on the bottom of the woocommerce stripe setting page. This is vital for capturing payments.
Example:
Let’s say your Stripe Test Publishable Key is `pk_test_XXXXXXXXXXXXXXX` and your Stripe Test Secret Key is `sk_test_YYYYYYYYYYYYYYY`. You’ll copy these into the “Test Publishable Key” and “Test Secret Key” fields, respectively.
Step 4: Configure Other Stripe Settings
The Stripe settings page offers several other options you can customize:
* Payment Request Buttons: Enable or disable Apple Pay, Google Pay, and other payment request buttons. These can significantly improve the checkout experience on mobile devices.
* Statement Descriptor: This is the name that will appear on your customers’ credit card statements. Use something recognizable and related to your business. Keep it short and sweet!
* Capture: Choose whether to authorize payments immediately or capture them later. Authorizing holds the funds on the customer’s card, while capturing actually charges them. For most businesses, immediate capture is the best option.
* Save Cards: Allow customers to save their credit card information for future purchases. This improves the convenience for returning customers.
* Logging: Enable logging to troubleshoot any issues with the Stripe integration.
Step 5: Test Your Discover insights on How To Set Up Woocommerce Shop Page Stripe Integration
Before going live, it’s crucial to thoroughly test your Stripe integration using test mode.
1. Make sure “Test Mode” is enabled.
2. Go to your WooCommerce store and add a product to your cart.
3. Proceed to the checkout page.
4. Select “Stripe – Credit Card (Stripe)” as your payment method.
5. Use a test credit card number from Stripe’s documentation ([https://stripe.com/docs/testing](https://stripe.com/docs/testing)). These are special card numbers that simulate successful and failed transactions in test mode.
For example, you can use `4242424242424242` as the card number, any expiration date in the future, and any 3-digit CVC.
6. Submit the order.
7. Check your Stripe dashboard to confirm that the test payment was processed successfully.
8. Also, test scenarios like declined payments (using a declined test card number) to ensure your store handles errors gracefully.
Step 6: Go Live!
Once you’ve thoroughly tested your Stripe integration and are confident that everything is working correctly:
1. Disable “Test Mode”.
2. Enter your Live Publishable Key and Live Secret Key from your Stripe dashboard.
3. Save your changes.
4. Run a real (small) transaction to ensure everything is working correctly in live mode. Then, immediately refund the transaction.
Troubleshooting Common Issues
* Invalid API Keys: Double-check that you’ve copied and pasted the correct API keys from your Stripe dashboard into your WooCommerce settings.
* SSL Certificate Issues: Make sure your website has a valid SSL certificate. Stripe requires HTTPS for secure transactions.
* Stripe Account Issues: Check your Stripe account for any error messages or notifications. Your account may need to be verified or may have restrictions in place.
* Plugin Conflicts: Sometimes, other plugins can interfere with the WooCommerce Stripe integration. Try temporarily disabling other plugins to see if that resolves the issue.
* Webhooks Configuration Learn more about How To Add Woocommerce Products In Oxygen 2.0 : Check your webhooks configuration Read more about How To Show Out Of Stock In Woocommerce with the exact value provided on the stripe settings page.
Conclusion
Setting up Stripe with WooCommerce may seem daunting at first, but by following these steps, you can easily integrate this powerful payment gateway into your online store. Remember to test thoroughly and always keep your API keys safe. Good luck and happy selling!