Skip to main content
Setting up sandbox credentials allows you to test M-Pesa payments in a safe development environment before going live.

Quick Start

For the sandbox environment, Moflay uses preconfigured shared credentials, so you can start testing immediately without any configuration. Simply navigate to the Moflay Dashboard and start making test payments right away.

Use Your Own Sandbox Credentials (Optional)

You can also use your own Daraja sandbox credentials for testing if you prefer to have full control over your test environment.
If you want to use your own credentials:
1

Create a Daraja Sandbox App

  1. Navigate to the Daraja Website.
  2. Click on Dashboard in the navigation bar.
  3. Click on My Apps in the sidebar.
  4. Click on Create Sandbox App.
  5. Enter your Application Name and select the Lipa na M-Pesa Sandbox checkbox.
  6. Click on Create App button.
2

Copy Your Consumer Key and Secret

  1. Once created, your app will appear in the sandbox apps list.
  2. Copy the Consumer Key and Consumer Secret.
3

Configure Consumer Key and Secret in Moflay Dashboard

  1. Navigate to Moflay Dashboard Credentials.
  2. Ensure you’re in the Sandbox environment.
  3. Paste your Consumer Key and Consumer Secret.

Next Steps

Once you’ve tested your integration in sandbox:
I