Title: Payment Gateway for M-PESA Open API on WooCommerce
Author: demkitech
Published: <strong>20 Γuct 2022</strong>
Last modified: 14 Yunyu 2026

---

Search plugins

![](https://ps.w.org/payment-gateway-for-m-pesa-open-api/assets/banner-772x250.png?
rev=2772845)

![](https://ps.w.org/payment-gateway-for-m-pesa-open-api/assets/icon-256x256.png?
rev=2772845)

# Payment Gateway for M-PESA Open API on WooCommerce

 By [demkitech](https://profiles.wordpress.org/dennokip/)

[Download](https://downloads.wordpress.org/plugin/payment-gateway-for-m-pesa-open-api.zip)

 * [Details](https://kab.wordpress.org/plugins/payment-gateway-for-m-pesa-open-api/#description)
 * [Reviews](https://kab.wordpress.org/plugins/payment-gateway-for-m-pesa-open-api/#reviews)
 *  [Installation](https://kab.wordpress.org/plugins/payment-gateway-for-m-pesa-open-api/#installation)
 * [Development](https://kab.wordpress.org/plugins/payment-gateway-for-m-pesa-open-api/#developers)

 [Support](https://wordpress.org/support/plugin/payment-gateway-for-m-pesa-open-api/)

## Description

The plugin enables the customer to have an option of paying merchants using M-PESA
mobile money service from a WordPress site that has WooCommerce plugin installed.

The plugin adds an option on the checkout section for paying through M-PESA(A mobile
payment platform) Open API which is now available on these counties: _Congo, Ghana,
Lesotho, Tanzania_

#### PLUGIN SETUP FOR M-PESA OPEN API SANDBOX

 * Testing of the plugin is possible by creating an account in the [M-Pesa Open API Developer Portal](https://openapiportal.m-pesa.com/).
 * After account creation, log in to the account, click on the menu at the top left
   corner of the portal.
 * Click on Applications from the drop down menu.
 * On the Applications window, click on New and fill the application details. Make
   sure you have chosen _C2B Single Payment_ option.
 * Once the application has been created, click on View option to check the application
   details.
 * The plugin settings are found here on your website once logged in as WordPress
   Administrator(WooCommerce ➡ Settings ➡ Payments ➡ M-PESA Open API ➡ Manage)
 * Copy the _Sandbox API Key_ value which you will fill in this plugin settings.
 * Open the C2B Single Payment documentation [here](https://openapiportal.m-pesa.com/api-documentation#APIRequests)
   and copy the _publicKey_ value on the sample code which you will paste in the
   plugin settings.
 * The _Country_ and _Currency_ to be configured on the plugin are in the _API Markets_
   table on the [Documentation](https://openapiportal.m-pesa.com/api-documentation)
   page.
 * Use _000000_ as the Service Code provided for testing on Sandbox
 * The endpoints will be prefilled but if not available copy from the documentation
   page.
 * After filling all these items on the plugin settings, click on Save and test 
   purchasing of products on the website.

**Note these items when testing in Sandbox:**
 1. You can add test numbers on the
M-Pesa Open API Portal. 2. This number(000000000001) will give a successful response
on Sandbox, but there will be no USSD Push received.

#### PLUGIN SETUP FOR M-PESA OPEN API PRODUCTION

 * The plugin settings will need to be changed to use the production details
 * Use the Go Live process on the M-Pesa Open API portal in order to get the production
   details
 * Once the Go Live process is successful and you have all the details, replace 
   them on the plugin settings, save and test.
 * Remember to update the endpoints too, to the production endpoints provided on
   the M-Pesa Open API documentation section.

#### PLUGIN CUSTOMER JOURNEY

 * When the customer clicks on the Pay button on the payment page, the plugin will
   initiate a payment authorization request to the customer.
 * The customer will then accept or decline the payment from the personal mobile
   phone.
 * The order status in the online shop is then changed depending on the customer’s
   action(In the Pro Version).
 * This **free version** of the plugin does not change order status and does not
   have the functionality of checking the transaction status of the payments but
   the Pro Version does.
 * The main purpose of the **free version** is to test the functionality of how 
   your website will work and it’s compatibility with your website before deciding
   to use it in production.
 * Please check the **DEMO** of the Pro Version of the plugin [HERE](https://demowoompesa.demkitech.com/)
 * The **Pro Version** is currently _Free_, please request for it by sending an 
   email to _info@demkitech.com_

#### Plugin features:

 * Compatible with WordPress themes.
 * Easy to use.
 * Lightweight.
 * Supports all modern browsers.

#### How to use:

 1. Make sure you have installed and activated WooCommerce plugin before installing
    and activating this plugin.
 2. Upload the Payment Gateway for M-PESA Open API on WooCommerce plugin files to the
    wordpress plugins directory (/wp-content/plugins/), or install the plugin from 
    th WordPress admin plugin screen.
 3. Activate the plugin.
 4. On the WordPress admin, navigate to (WooCommerce ➡ Settings ➡ Payments ➡ M-PESA
    Open API ➡ Manage) and fill in the fields provided in order for the plugin to work.

#### Demo Video

Coming Soon

### Disclaimer

This plugin does not have any relation with WooCommerce or M-PESA. The plugin’s 
purpose is just to help in linking the WooCommerce plugin with the M-PESA payment
method.
 In the plugin description there is links to other websites which are not
under the control of Payment Gateway for M-PESA Open API Plugin. We have no control
over the nature, content and availability of those sites. The inclusion of any links
does not necessarily imply a recommendation or endorse the views expressed within
them.

## Screenshots

[[

[[

[[

[[

## Installation

 1. Unzip files.
 2. Upload the folder into your plugins directory.
 3. Activate the plugin.
 4. Update the settings.

## FAQ

How does the customer authenticate the payment?
 The customer receives a USSD push
to authenticate the payment and this is secure since it is the customer doing this.

## Reviews

There are no reviews for this plugin.

## Contributors & Developers

“Payment Gateway for M-PESA Open API on WooCommerce” is open source software. The
following people have contributed to this plugin.

Contributors

 *   [ demkitech ](https://profiles.wordpress.org/dennokip/)

[Translate “Payment Gateway for M-PESA Open API on WooCommerce” into your language.](https://translate.wordpress.org/projects/wp-plugins/payment-gateway-for-m-pesa-open-api)

### Interested in development?

[Browse the code](https://plugins.trac.wordpress.org/browser/payment-gateway-for-m-pesa-open-api/),
check out the [SVN repository](https://plugins.svn.wordpress.org/payment-gateway-for-m-pesa-open-api/),
or subscribe to the [development log](https://plugins.trac.wordpress.org/log/payment-gateway-for-m-pesa-open-api/)
by [RSS](https://plugins.trac.wordpress.org/log/payment-gateway-for-m-pesa-open-api/?limit=100&mode=stop_on_copy&format=rss).

## Changelog

#### 1.0

## Meta

 *  Version **1.0.0**
 *  Last updated **4 n wagguren ago**
 *  Active installations **20+**
 *  WordPress version ** 2.2 or higher **
 *  Tested up to **7.0.7**
 *  Language
 * [English (US)](https://wordpress.org/plugins/payment-gateway-for-m-pesa-open-api/)
 * Tags
 * [M-PESA](https://kab.wordpress.org/plugins/tags/m-pesa/)[Mobile Payments](https://kab.wordpress.org/plugins/tags/mobile-payments/)
   [MPESA](https://kab.wordpress.org/plugins/tags/mpesa/)[payment gateway](https://kab.wordpress.org/plugins/tags/payment-gateway/)
   [woocommerce](https://kab.wordpress.org/plugins/tags/woocommerce/)
 *  [Advanced View](https://kab.wordpress.org/plugins/payment-gateway-for-m-pesa-open-api/advanced/)

## Ratings

No reviews have been submitted yet.

[Your review](https://wordpress.org/support/plugin/payment-gateway-for-m-pesa-open-api/reviews/#new-post)

[See all reviews](https://wordpress.org/support/plugin/payment-gateway-for-m-pesa-open-api/reviews/)

## Contributors

 *   [ demkitech ](https://profiles.wordpress.org/dennokip/)

## Support

Got something to say? Need help?

 [View support forum](https://wordpress.org/support/plugin/payment-gateway-for-m-pesa-open-api/)

## Donate

Would you like to support the advancement of this plugin?

 [ Donate to this plugin ](https://kab.wordpress.org/plugins/payment-gateway-for-m-pesa-open-api/?output_format=md#)