>  Uncategorized   >  WC-Mpesa : Linking Mpesa with Paypal.
Safaricom M-Pesa Daraja API

Last Saturday I attended WordPress meetup at Nairobi Garage, Ngong road. A lot of people, mainly Kenyans have been struggling with linking their Mpesa with Paypal. I was happy that Paypal added an M-PESA button that allows you to transfer money from Paypal straight to your phone. However, there were difficulties in linking the two.

Safaricom Daraja team, Daraja is Swahili for bridge.

My Take on WC-MPESA

I arrived 15 minutes late and Safaricom Daraja Team were almost done with their presentation. I was using Google Map and had only 4 hours of sleep in two days. The Daraja team explained in details the new M-PESA API and they will be doing so again so stick around for dates on that..


I am not a tech person, so it was definitely out of my comfort zone and I would love to see what I can learn and if this is open to freelancers and not only store or Etsy owners. I will include details down below of how you can contact Mauko, the WordPress Developer who took us through how to setup WordPress for eCommerce and accepting payments using M-PESA.


 However, I learnt something or two from the Daraja Team;

  • You have to create a Daraja app on the Safaricom Development Portal for you to link the two.
  • The plugin installation is downloaded from Github.
  • To configure, check for live,  don’t check if you are testing. To configure you will need the  consumer key that you created from the Daraja App,I believe they called it short-code, I am not sure.
  • The configuration enables Lipa na Mpesa (Pay via Mpesa). The plugin is added on the WP dashboard and can be installed.

Account Name.

  • For the account name, change from WC(Woo Commerce) to the name of your business.
  • Accountant; attributes the user to the post. It helps reconcile payments and transactions. If the customer sends money directly via phone rather from the business account, or transactions not initiated by the plugin. It harmonizes payments.
  • The plugin must be enabled for it to show up as a payment option. It is added to the check out page of the store.
  • A buyer wishing to make a purchase  clicks on the place order button and there follows a pop up on his/her phone with the order number and the order is processed.
  • The Check out page of the store records the customers name , amount and adds notes ( eg, awaiting M-PESA payments, if not yet paid for).
  • Once paid the receipt number is added as order note.


When configuring the plugin;

  • Make the Daraja app on the Safaricom Development portal.
  • Ensure your site is running on GBTS.
  • Register so as to notify M-PESA where to send the responses.


The plugin is open source (thanks Mauko!) and licensed under MIT license. It handles everything but can’t check balances or do reversals.
The pro-version features:

  • Transaction status check.
  • Account Balance check.
  • Transaction Reversal.
  • B2B transfer.
  • B2C transfer.


Overall, I think this is great and M-PESA will help a lot. I want to try this process within the first two weeks of June and see if I get it done. I should have asked whether the Daraja app is usable to Freelancers, writers etc. I will get that information and update you.

If you are interested and having problems, visit the Safaricom Development Portal and seek help on the FAQs and DOCs section. You can also contact Mauko at


You may also Like: WordCamp Nairobi
Subscribe to my email list to get my two cents on how to Live, Love & Inspire here