Photo by Dino Reichmuth on Unsplash
How to Incorporate Paystack Payment Gateway on Your WordPress WooCommerce Store
If you’re running an online store with WooCommerce, integrating a reliable payment gateway is crucial for ensuring smooth transactions. Paystack is an excellent option for businesses in Nigeria, Ghana, Kenya, and South Africa. In this guide, we’ll walk you through the process of incorporating the Paystack payment gateway into your WordPress WooCommerce store.
Step 1: Install the Paystack WooCommerce Plugin
Log in to Your WordPress Dashboard:
- Navigate to the admin panel of your WordPress website.
Add a New Plugin:
- Go to
Plugins > Add New
from the left-hand menu.
- Go to
Search for Paystack WooCommerce Payment Gateway:
- Use the search bar to find the plugin by typing "Paystack WooCommerce Payment Gateway."
Install and Activate the Plugin:
Click the "Install Now" button when you see the plugin by Tunbosun Ayinla.
After installation, click "Activate" to enable the plugin on your site.
Step 2: Configure Paystack in WooCommerce
Access WooCommerce Settings:
- Navigate to
WooCommerce > Settings
from your WordPress dashboard.
- Navigate to
Go to the Payments Tab:
Click on the "Payments" tab within the WooCommerce settings.
You should see Paystack listed as one of the payment methods.
Set Up Paystack:
- Click on the "Set Up" or "Manage" button next to Paystack.
Enable Paystack:
- Check the box labeled "Enable/Disable" to activate Paystack as a payment method.
Customize the Title and Description:
Title: This is how Paystack will appear in the payment options during checkout. For example, "Debit/Credit Card via Paystack."
Description: Provide more details to customers, such as supported payment methods (e.g., Credit/Debit Cards, Bank Transfer, Mobile Money).
Step 3: Configure API Keys
To connect your WooCommerce store with Paystack, you’ll need API keys from your Paystack Dashboard.
Log in to Your Paystack Dashboard:
- Go to Paystack Dashboard and log in.
Navigate to API Keys & Webhooks:
- Click on "Settings" in the dashboard menu and then select "API Keys & Webhooks."
Copy Your API Keys:
Test Mode Keys: Use these for testing transactions.
Live Mode Keys: Use these for real transactions.
Enter API Keys in WooCommerce:
- Paste the appropriate keys (Test or Live) into the respective fields in the Paystack WooCommerce plugin settings.
Enable Test Mode (Optional):
- If you want to test the integration before going live, check the "Enable Test Mode" box.
Step 4: Configure Webhook URL
Paystack uses webhooks to send transaction notifications to your store. To set this up:
Find the Webhook URL in WooCommerce:
- The plugin configuration page will display a webhook URL (e.g.,
https://yourstore.com/wc-api/WC_Gateway_Paystack
).
- The plugin configuration page will display a webhook URL (e.g.,
Add the Webhook URL to Paystack:
Go back to your Paystack Dashboard.
Under "API Keys & Webhooks," paste the webhook URL into the Webhook URL field.
Save Changes:
- Click "Save" to complete the webhook configuration.
Step 5: Test the Integration
Before accepting live payments, it’s essential to test the setup:
Enable Test Mode in WooCommerce:
- Go to the Paystack plugin settings and check "Enable Test Mode."
Use Test Card Details:
- Paystack provides test card details for you to simulate transactions. You can find these in the Paystack Documentation.
Perform a Test Transaction:
Add a product to your cart and proceed to checkout.
Select Paystack as the payment method and complete the test transaction.
Verify the Test Transaction:
- Check your Paystack Dashboard to ensure the test transaction is recorded.
Step 6: Go Live
Once you’re satisfied with the test results:
Disable Test Mode:
- Go to the Paystack plugin settings and uncheck "Enable Test Mode."
Enter Live API Keys:
- Replace the Test API Keys with your Live API Keys.
Save Changes:
- Click "Save" to finalize the configuration.
Perform a Live Transaction:
- Conduct a small live transaction to confirm everything works as expected.
Step 7: Start Accepting Payments
Congratulations! Your WooCommerce store is now integrated with Paystack. You can start accepting payments through various methods, such as Credit/Debit Cards, Bank Transfers, and Mobile Money, depending on your region.
Tips for Managing Paystack Payments
Enable Logging:
- Turn on logging in the plugin settings to troubleshoot any payment issues.
Monitor Transactions:
- Regularly check your Paystack Dashboard for transaction updates.
Keep API Keys Secure:
- Never share your API keys with unauthorized individuals.
By following these steps, you can seamlessly incorporate the Paystack payment gateway into your WooCommerce store, providing your customers with a secure and flexible way to make payments.