Back to Blog
Guides 5 min read

How to Get Your M-Pesa Daraja API Credentials

DS

Deluxe Sande

Jan 28, 2026

To integrate M-Pesa payments into SaleSense (or any custom website), you need two critical pieces of information: the **Consumer Key** and the **Consumer Secret**. These are generated on Safaricom's developer portal, known as Daraja.

Step 1: Sign up on Daraja

Navigate to the Safaricom Developer Portal (developer.safaricom.co.ke). If you don't have an account, sign up as an individual or company. If you already have one, simply log in.

Step 2: Create a New App

Once logged in, click on the **'My Apps'** tab in the top navigation bar. Then click the **'Create New App'** button.

Name your app (e.g., 'SaleSense Integration').

Ensure you check the box for **Lipa na M-Pesa Sandbox** (for testing) or the specific production products you need.

Note:Important: You must check at least one product option (like Lipa na M-Pesa) or the app creation will fail.

Step 3: Copy Your Credentials

After creating the app, click on it from your list. You will see two tabs: 'Keys' and 'Products'. Under the **Keys** tab, you will find:

  • Consumer Key: (A long string of random characters)
  • Consumer Secret: (Another long string)

Copy these keys and paste them into your SaleSense settings page to enable automatic payment tracking.

Ready to grow your business?

Join thousands of Kenyan businesses using SaleSense to streamline operations, track M-Pesa payments, and stay KRA compliant.