An attractive Magento store isn’t enough to convert your website visitors into paying customers. You also need a smooth checkout process.
Baymard Institute’s survey of 4,384 U.S. online shoppers revealed that two of the top ten reasons for checkout abandonment were:
1. Customers couldn’t trust the website with their credit card information.
2. The website didn’t offer enough payment methods.
Magento’s default payment module is a reliable and secure way to accept payments online. But when you’re competing globally, you need more than helpful defaults.
This guide will explain everything you need to know about implementing a Magento payment gateway and share five recommendations for different use cases.
Here’s what we’ll cover:
Magento Payment Gateway
A Magento payment gateway is a service that helps business owners accept online payments by connecting their stores with a third-party payment processor. It acts as a “gateway” that encrypts and transmits credit card information to the payment service provider.
It’s important to understand that a payment gateway works differently from a payment processor. Payment gateways only collect, encrypt, and transmit transaction details from the website to the processor. It’s the payment processor that completes the actual transaction.
Payment gateways usually charge a fee for their service. For instance, Stripe and PayPal charge a percentage and fixed fee per transaction.
How To Choose the Best Magento Payment Gateway?
Magento payment gateways come in different shapes and sizes. Before you choose the right one for your business, ask yourself these questions:
1. What payment options does your target audience prefer?
2. How often do you process refunds?
3. How many currencies do you support?
Once you have the answers, check the following requirements.
Transaction Fees and Pricing Structure
Like most third-party services, ecommerce payment gateways charge a fee for their convenience. A percentage-based fee and fixed cost per transaction are the norms. But some payment platforms charge additional setup fees and monthly gateway fees as well.
Review the pricing structure of different Magento payment gateways before creating a merchant account. Too many fees or complicated pricing structures can quickly eat into your profit margin.
Payment Method Support
A payment method is how customers pay your business through the payment gateway. Common payment methods used for online transactions include credit cards, debit cards, cryptocurrency, and eWallets.
Make sure you choose a Magento 2 payment gateway that supports the payment methods used by your customers. For example, B2B customers might prefer to pay via bank transfers and company cards, whereas B2C customers might prefer card or eWallet payments.
Extra Features Offered
If you’re selling globally, you will need multicurrency and multilingual support. Similarly, if you’re using Magento 2 bundle products to sell subscription boxes, you’ll need a payment gateway that supports recurring payments.
Thus, choosing a Magento payment gateway that offers the functionality your business needs is crucial. Check currency conversion rates and markups on international cards to avoid last-minute surprises.
Credit card fraud is a significant challenge for every online business. According to the 2021 annual report by Nilson Report, losses due to card fraud globally exceeded $28.58 billion in 2020. And Nilson expects that number will reach $49.32 billion by 2030.
It’s vital to ensure your Magento payment gateway implements security measures to protect your customer’s credit card details and offers seller protection features like fraud detection and prevention.
5 Best Magento Payment Gateways
There are hundreds of payment gateways on the market. But not every gateway offers the same features or services. Here’s how the top five Magento payment gateways on the market compare.
With over 429 million active user accounts as of Q1 2022, according to Statista, PayPal is the largest payment gateway and processor on the market. But the fact that PayPal is built into Magento makes it the best payment gateway for Magento users.
PayPal’s simple user interface (UI) and comprehensive feature set make it ideal for small businesses. Moreover, with PayPal Express Checkout, you can accept online payments without installing Magento 2 extensions. You only need a PayPal business account to get started.
Pre-integrated with Magento 2.Buy now, pay later and PayPal Credit payments (U.S. only).Recurring payments.Touch-free QR code payments.100+ currencies across 200+ markets.
Pricing: 3.49% +$0.49 per transaction for PayPal payments. 2.59% +$0.49 per transaction for credit and debit cards.
Best Magento payment gateway for: Merchants who need to launch quickly and offer an uncomplicated customer experience.
Stripe is a developer-friendly payment service provider ideal for businesses of all sizes. Stripe isn’t a truly out-of-the-box payment solution like PayPal, but it makes up for it with amazing features like 3D Secure and an intuitive UI.
For multichannel merchants who sell through a brick-and-mortar store, Stripe offers Terminal, a software that lets you accept payments offline using a point of sales system. And for online-only merchants, it supports alternative methods like Alipay and Bitcoin.
Sophisticated machine learning fraud protection.135+ currencies.PCI DSS Level 1 certified.Recurring payment support.Hosted payment page that supports 30+ languages.
Pricing: 2.9% + $0.30 per successful card charge.
Best Magento payment gateway for: Merchants who need a scalable payment gateway and support for multiple Magento payment methods.
Square is famous for its point of sale system that enables merchants to accept offline customer payments. But it also offers a customizable payment gateway to accept digital payments called Square Online.
Square enables offline stores to start selling online with a code-free setup experience. Its social media integrations and multiple payment method support make Square the best payment gateway for merchants who want simplicity and value.
Support for all major credit cards and alternative methods like Apple Pay and Cash App.No monthly fees or fees for refunds or chargebacks.Free fraud protection.Next business day payment transfers.Free POS app.
Pricing: Starts from 2.9% + $0.30 per transaction.
Best Magento payment gateway for: Merchants who need a simple payment gateway that integrates with their brick-and-mortar store.
Braintree, owned by PayPal, offers a better UI and supports more payment methods, making it an excellent choice for Magento merchants. You continue to enjoy the benefits of using PayPal, such as PayPal Credit and PayPal One Touch.
However, you can support alternative payment methods such as Apple Pay and Google Pay. Braintree takes a tech-centric approach to its service, competing with Stripe as a developer-friendly and scalable Magento payment gateway.
130+ currencies and 45+ countries.Customizable Drop-in UI for a streamlined checkout experience.Code-free setup.3D Secure 2 — fraud protection.Supports PayPal, Venmo, Apple Pay, Google Pay, and more.
Pricing: 2.59% + $0.49 per transaction.
Best Magento payment gateway for: Magento merchants who want to use PayPal but need a more customizable gateway.
Amazon’s proprietary payment gateway, Amazon Pay, provides you access to millions of customers globally. You also get flexible integration options and a fully optimized mobile payment experience from one of the world’s most successful ecommerce businesses.
Amazon Pay accepts most major credit and debit cards and is a great payment gateway if you want to move away from selling on marketplaces.
Easy setup process.Clear pricing schedule.Support for all major credit and debit cards, including Visa, Mastercard, Discover, American Express, and Diners Club.Free fraud detection capabilities, chargeback controls, and risk management processes.1- to 2-day disbursements.
Pricing: 2.9% on domestic transactions and 3.9% on international transactions with a $0.30 fixed fee on both.
Best Magento payment gateway for: Multichannel merchants who sell on Amazon in addition to their online store.
How To Integrate Stripe With Magento 2
If you want to integrate a payment gateway in Magento, consider using Stripe. With a 16.76% market share, Stripe is the world’s second most popular payment gateway, according to Datanyze. It supports multiple payment methods and offers robust seller protection.
Here are the steps you can follow to integrate Magento 2 with Stripe.
Note: Test the integration on a test server before trying it on your production store. And if you’re using a Magento version below 2.4.0, reference Stripe’s documentation for the extra steps needed to configure webhooks.
1. Install the Official Stripe Extension for Magento 2
Purchase the free Stripe Magento 2 payment gateway extension from the Magento Marketplace.
Log into your Magento 2 server and run the following command from the project root to install the Stripe extension for Magento 2 using Composer:
$ composer require stripe/stripe-payments
Once the above command executes, run the following commands:
$ php bin/magento setup:upgrade
$ php bin/magento cache:flush
$ php bin/magento cache:clean
If you’re running Magento in Production mode, run the following two commands:
$ php bin/magento setup:di:compile
$ php bin/magento setup:static-content:deploy
2. Create New Test API Keys in Your Stripe Account
Sign in to your Stripe account and go to Developers > API keys.
Toggle the Test mode switch and copy the test API keys for your store.
3. Configure Stripe in the Magento 2 Admin
Log in to the Magento 2 admin panel and navigate to Stores > Configuration > Sales > Payment Methods > RECOMMENDED SOLUTIONS > Stripe.
Click Configure, expand the General settings section, ensure Mode is set to Test, and paste your test keys into the Test publishable API key and Test secret API key text areas.
Expand the Payments section and set Enabled to Yes.
Set the Payment flow to Embed payment form into the native flow or Redirect customers to Stripe Checkout.
Enter a descriptive Title to display on the checkout page.
Optionally, configure the Magento 2 Payment methods by clicking on the blue Configure hyperlink, which redirects to the Stripe dashboard.
Set the Payment Action as Authorize and Capture.
To allow customers to save their payment method configuration, set Save customer payment method to Enabled (or Disabled if you want customers to enter their details every time).
Use the Card CVC code setting to choose when to collect CVC codes.
Optionally, add a statement descriptor in the Optional statement descriptor text field and set the Sort order for the checkout page.
You can also configure additional settings using the Wallet Button, Fraud via Stripe Radar, and Subscriptions via Stripe Billing sections. Once you’re ready to test the payment integration, click the Save Config button.
4. Verify the Magento Payment Gateway Integration
Navigate to the front end, add products to your cart, and proceed to checkout. Use Stripe’s test card numbers to complete payment.
Once the payment is complete, navigate to the Magento admin panel and access the order management dashboard. Verify that the order has come through and the status shows “Processing.”
Open your Stripe account dashboard and check if the transaction displays in your test dashboard. If it does, you’ve successfully integrated Magento 2 with Stripe and can start using the live keys to accept online payments.
5. Switch to the Live Mode
Open the Stripe dashboard and go to Developers > API keys. Switch the Test mode toggle off and click the + Create secret key button in the Standard keys section.
Once you’ve created your live keys, copy them and go back to the Magento admin.
Navigate to Stores > Configuration > Sales > Payment Methods > RECOMMENDED SOLUTIONS > Stripe. Click on Configure, expand the General settings section, and set Mode to Live.
Paste your keys into the Live publishable API key and Live secret API key sections
Change Test Mode to No, add the live keys, and click Save Config.
That’s it. Your Magento store is now ready to accept payments from customers via Stripe.
Final Thoughts: A Merchant’s Guide to the Best Magento Payment Gateways
A secure, efficient, and fast Magento payment gateway can improve the checkout experience and boost conversions. More importantly, it can give you and your customers peace of mind.
If you’re worried about the safety of your Magento store, consider signing up for Managed Magento Hosting with Nexcess. You’ll get access to PCI-compliant Magento hosting and proactive security.
Browse our plans to get started today.