The Stripe payment option lets customers pay you using a credit card or debit card. While some payment options take your customers to the payment gateway’s site to make payment, with Stripe customers remain on your site to enter their card details.
Getting your API keys
To connect your site to Stripe you need to get your Stripe API keys. There are two sets of API keys: test keys allow you to test your account without transferring money, while live keys are used to take payments.
To get your test API keys, log in to your Stripe account and click Get your test API keys. You will see a panel like this:
Your secret key will initially be hidden. Click on the eye icon to reveal it:
You can click on each key to copy it to the clipboard.
To get your live API keys, click Activate your Stripe account and activate your account. Once your account has been activated, click Get your live API keys.
Setting up Stripe in your shop
To set up Stripe in your shop, click Payment in the shop admin panel menu and then click Stripe. You can then change the following settings:
Whether Stripe is available as a payment method.
Whether to perform test payments or live payments.
Where the payment method is available — either one of the delivery regions set up in your shop or the special value Everywhere.
Test public key
The test public/publishable key. This key will start pk_test_.
Test secret key
The test secret key. This key will start sk_test_.
Live public key
The live public/publishable key. This key will start pk_live_.
Live secret key
The live public/publishable key. This key will start sk_live_.
You only need to enter the keys for the mode than you currently using, so the live keys can be left blank until you switch to live mode.
When in test mode you can use the card number 4000 0027 6000 3184, along with any future expiry date and security code. This card has 3D Secure enabled, so a pop-up window will be shown asking you to authorise the transaction. In live mode the pop-up window will show a message from the customer’s bank asking for the authentication details required by the bank (such as a code sent to the customer in a text message).