# Connect your Payfast account

> Take cards, Instant EFT and Masterpass in South Africa with your own Payfast account. In Settings > Payments, click Set up Payfast, paste your merchant ID, merchant key and passphrase, choose Live or Test, switch it on and click Save settings.

Help Centre / Payments - Updated 19 November 2026

Payfast is a payment provider for businesses in South Africa. When you connect your Payfast account, your customers can pay by card, by Instant EFT from their own bank, or with Masterpass. Payments go straight to your Payfast account, and Shoprocket takes 0%.

When a customer clicks **Pay now**, a secure Payfast window opens over your checkout. They pay there and stay in your shop the whole time. Card and bank details go straight to Payfast and never pass through Shoprocket.

## Before you start

You need a Payfast account and three details from your Payfast dashboard:

1. Your **Merchant ID** and **Merchant Key**, from **Settings > Merchant Details**.
2. A **passphrase**. If you have not set one yet, add it under **Settings > Integration**. Choose something long that you don't use anywhere else. Payfast uses it to sign every payment, so the passphrase in Shoprocket must match the one in Payfast exactly.

## Connect Payfast

1. In your dashboard, go to **Settings > Payments**.
2. On the Payfast card in **Payment gateways**, click **Set up Payfast**.
3. Paste your **Merchant ID**, **Merchant Key** and **Passphrase** into the fields with the same names.
4. Under **Mode**, choose **Live**.
5. Turn Payfast's switch to **On** and click **Save settings**.

![The Payfast card in Settings > Payments: the merchant ID, merchant key, passphrase and mode fields](https://shoprocket.io/img/help/connect-payfast/payfast-setup.webp)

When you save, Shoprocket checks your merchant ID and passphrase with Payfast. If Payfast rejects them, nothing is saved and a message at the top of the screen says why. The most common mistake is a passphrase that differs from the one in **Settings > Integration**, even by a space at the end.

The card then says **Connected**, and Payfast appears at your checkout.

There is no webhook to set up. Shoprocket tells Payfast where to report each payment. Before it marks an order paid, it checks that report with Payfast.

## Payfast takes rand only

Payfast takes payments in South African rand (ZAR). The card shows **Your Payfast account takes payments in ZAR** once you save.

If your shop is priced in another currency, the card warns you. Payfast can't be your main card gateway in that case, but you can still offer it to customers paying in rand. To do that, add ZAR under **Card gateway by currency**, as [Choose a payment gateway](https://shoprocket.io/help/choose-a-payment-gateway.md) explains.

## Try it with a Payfast sandbox account

Payfast's test environment is a separate account. Sign up for one at sandbox.payfast.co.za. It has its own merchant ID, merchant key and passphrase.

To try your checkout without moving real money:

1. Click **Edit Payfast credentials**.
2. Paste the merchant ID, merchant key and passphrase from your **sandbox** account.
3. Under **Mode**, choose **Test (Payfast sandbox account)** and click **Save settings**.

The card then shows **Test credentials: no real money moves**. In test mode, **Pay now** takes the customer to Payfast's sandbox payment page instead of opening the window over your checkout, because Payfast's sandbox doesn't offer that window. Pay with one of Payfast's test cards, and you come back to your shop with the order confirmed.

When you are ready to sell, click **Edit Payfast credentials** again, paste the details from your live Payfast account, choose **Live** and click **Save settings**.

## How customers pay

- **Customers can pay by card.** They type their card details in the Payfast window. If their bank needs to check the payment, the check opens there too.
- **Customers can pay by Instant EFT.** They log in to their own bank in the Payfast window and approve the payment. The order is confirmed as soon as Payfast tells us the money is through.
- **Customers can pay with Masterpass.** They scan the code with their banking app.

If a customer closes the Payfast window without paying, they are back in their cart and can click **Pay now** to try again.

## Refunds

When you refund an order paid with Payfast, Shoprocket sends the refund to Payfast, in full or in part. See [Refund an order](https://shoprocket.io/help/refund-an-order.md).

Payfast only lets you refund through Shoprocket when your Payfast account has API access. If it doesn't, the first refund shows as failed and says so. Refund the customer in your Payfast dashboard, then refund the order again in Shoprocket. Shoprocket then asks you to confirm that you have sent the money yourself, and records the refund on the order. Orders paid in test mode are always refunded this way, because Payfast's sandbox has no refunds.

Refunds come out of your Payfast balance, so keep enough in it to cover them.

## Subscriptions

Payfast can't renew subscriptions on Shoprocket yet. If you sell subscriptions, keep another card gateway that renews them, such as Stripe or Paystack, for those products.

## Changing your credentials or turning it off

After you connect Payfast, its button reads **Edit Payfast credentials**. Your saved credentials are stored encrypted and never shown again. To keep them, leave the fields blank. To replace them, fill in all four fields and click **Save settings**.

To stop offering Payfast, turn its switch to **Off** and click **Save settings**. Your credentials stay saved, so you can switch it back on at any time. Payments your customers have already started will still go through.

## Related

- [Choose a payment gateway](https://shoprocket.io/help/choose-a-payment-gateway.md)
- [Refund an order](https://shoprocket.io/help/refund-an-order.md)
- [Take a test order](https://shoprocket.io/help/take-a-test-order.md)

[Open Payments in your dashboard](https://app.shoprocket.io/go/settings/payments)

---

- HTML version: https://shoprocket.io/help/connect-payfast
- Language: English (en)
- Also in: [العربية](https://shoprocket.io/ar/help/connect-payfast.md), [Deutsch](https://shoprocket.io/de/hilfe/payfast-konto-verbinden.md), [Ελληνικά](https://shoprocket.io/el/help/connect-payfast.md), [Español](https://shoprocket.io/es/ayuda/conectar-payfast.md), [Français](https://shoprocket.io/fr/aide/connecter-payfast.md), [עברית](https://shoprocket.io/he/help/connect-payfast.md), [हिन्दी](https://shoprocket.io/hi/help/connect-payfast.md), [Bahasa Indonesia](https://shoprocket.io/id/bantuan/hubungkan-akun-payfast.md), [Italiano](https://shoprocket.io/it/aiuto/collega-payfast.md), [日本語](https://shoprocket.io/ja/help/connect-payfast.md), [Lietuvių](https://shoprocket.io/lt/pagalba/prijunkite-payfast-paskyra.md), [Norsk](https://shoprocket.io/nb/hjelp/koble-til-payfast-kontoen-din.md), [Nederlands](https://shoprocket.io/nl/hulp/payfast-account-koppelen.md), [Polski](https://shoprocket.io/pl/pomoc/polacz-konto-payfast.md), [Português](https://shoprocket.io/pt/ajuda/conectar-payfast.md), [Română](https://shoprocket.io/ro/ajutor/conecteaza-contul-payfast.md), [Русский](https://shoprocket.io/ru/help/connect-payfast.md), [ไทย](https://shoprocket.io/th/help/connect-payfast.md), [Türkçe](https://shoprocket.io/tr/yardim/payfast-hesabi-baglama.md), [中文](https://shoprocket.io/zh/help/connect-payfast.md)
