Blog » Payment gateway integration: A step-by-step guide for small businesses in South Africa

Payment gateway integration: A step-by-step guide for small businesses in South Africa

Starting your online shop is one thing, but figuring out how to get paid reliably in rands is another. As a small business owner you need a solution that is simple, cost-effective and trusted by your local customers. 

This guide breaks down the often-overthought process of payment gateway integration. We will focus on the most straightforward path for merchants using popular platforms like Shopify and WooCommerce in South Africa, addressing the key technical points without making your head spin. 

What you need before you start payment gateway integration 

Before you look at a single line of code or a plugin, every business needs to meet a few core requirements for plugin integration. Think of these as your non-negotiables: 

  • A fully operational business bank account: Your chosen payment processor needs a place to pay your money into. This must be a South African account. 
  • A secure website (https): You need an SSL certificate. All modern website hosting and platforms provide this, turning your address from http to https. This secures the connection between your customers and your server, which is an absolute basic security measure. 
  • Basic legal compliance: This is about trust. You must have clear Terms & Conditions, a Privacy Policy (essential for POPIA compliance), and a transparent refund/return policy visible on your site. 

If you are just getting started, the very first step is to secure a merchant account with a local payment gateway. You can easily sign up for a Payfast by Network account here

The big decision: API vs. Plugin

Your approach to how you integrate a payment gateway in your website depends entirely on your platform and technical comfort level. 

  • The plugin approach (recommended for 99% of small businesses): This is the “easy button.” You install a piece of software (a plugin or extension) that handles the complex technical connection for you. 
  • The custom approach: This uses a Payment Gateway API, which is a set of rules and protocols, to build the checkout functionality yourself. This is typically only done for highly customised sites or specific developer projects using languages like PHP. If you are using Shopify or WordPress/WooCommerce, you can skip this. 

The easiest path: Plugin integration (WooCommerce & Shopify)

For a small business the best path to online payments is almost always a pre-built connector provided by a local payment gateway service. This handles most of the technical security and compliance behind the scenes. 

WooCommerce (WordPress payment gateway integration)

If your shop is built on WordPress using WooCommerce, you are in luck. This is the most popular e-commerce combination in South Africa and local processors offer direct, free plugins. 

The set up generally follows a similar pattern to the below: 

  • Get your credentials: Sign up with a local payment gateway. Once approved, you will receive a unique Merchant ID and a Merchant Key. Think of these as the username and password for your gateway account. 
  • Install the plugin: In your WordPress Admin dashboard, navigate to Plugins > Add New, search for your chosen gateway’s plugin, and click ‘Install’ and ‘Activate’. 
  • Configure: Navigate to WooCommerce > Settings > Payments and click ‘Set up’ on the new gateway option. Paste in your Merchant ID and Merchant Key. That’s it. 

This WordPress payment gateway integration method is simple, reliable and means you don’t need to hire a developer for a simple setup. 

Shopify plugin integration

Shopify is slightly different as its payment options are managed directly through its centralised system. 

  • Native providers: Shopify often encourages using its own system, Shopify Payments, but many local merchants prefer a South African payment gateway for lower fees or local payment method support (like Instant EFT). You can check the features and pricing of the various options to find the best fit. 
  • The setup: For many SA-based gateways, you simply select them from the list of ‘Third-party payment providers’ in your Shopify settings. You will be redirected to the provider’s site to log in and connect your account. The process is designed to be user-friendly and requires just a few clicks. 

Using a plugin or the platform’s native connection is how the vast majority of merchants in the country manage payment gateway shopify connections. 

When you need a custom integration

Maybe you are a developer, or perhaps your business is building a non-traditional application: such as a mobile app or a specific booking system. This is where a custom integration using the Payment Gateway API becomes relevant. 

This involves: 

  • Server-Side code: Writing code (often in PHP or similar) to securely communicate with the gateway’s servers. You would need to consult the developer documentation
  • Security: Handling complex steps like hashing the data and redirecting the customer securely. 
  • Notifications: Setting up an Instant Transaction Notification (ITN) URL so the gateway can instantly tell your website if a payment was successful or failed. 

If you’re selling products on a standard WooCommerce or Shopify site, you don’t need payment gateway integration services for a full custom build. The plugins do the work for you. 

How to integrate your payment gateway

The goal of today should be to minimise risk and time. 

  • Choose a local processor: Pick a South African payment processor that offers the best transaction rate and the local payment types your customers use (EFT, credit card, digital wallets and more). 
  • Use the plugin/extension: Leverage the free, official plugin for your platform. This is the most cost-effective and fastest for your website to accept payments. 
  • Check compliance: Remember, the gateway handles card security (PCI DSS), but you are still responsible for your store’s legal compliance. The Electronic Communications and Transactions Act (ECTA) governs much of e-commerce in South Africa, so check that your policies are up to scratch. 

Ready to launch? The hard work is already done by these simple tools. It is time to connect and sell!