How to Test Stripe Payments Before Accepting Real Payments

Do you want to test Stripe transactions before accepting real payments in WPForms? You can make trial purchases using test credit card numbers on your site and analyze the transactions by logging into your Stripe account. In this article, we’ll show you how to perform test Stripe transactions on your site.

  1. Enable Stripe Test Mode
  2. Create a Form to Test Stripe Payments
  3. Enable Stripe Payments
  4. Publish Your Form and Perform the Test
  5. View Test Transactions on Your Stripe Account

Requirements: You will need a Pro license level or higher to access the Stripe addon.


1. Enable Stripe Test Mode

Before we get started, be sure to install WPForms on your WordPress site. Then, you’ll need to have the Stripe addon installed in order to test Stripe payments on your site.

To begin testing the form, we’ll need to ensure that no real payments are made in the process. To do this, navigate to WPForms » Settings and go to the Payments tab.

Open Payments tab of WPForms settings

On this page, scroll to the Stripe section to select the Test Mode checkbox.

You should also check that there’s a green checkbox for the Connection Status. This lets you know that your site has been successfully connected to your Stripe account.

Stripe is connected and test mode is enabled

Note: If you haven’t already connected your site to your Stripe account, you’ll be reminded to set up Stripe Connect. This will let your site send payment data to your Stripe account, and must be configured separately for live and test payments.

After you’ve checked that Stripe is connected and test payments are enabled, click the Save Settings button.

2. Create a Form to Test Stripe Payments

Next, you’ll either need to create a new form or edit an existing form with WPForms. In our example, we’ll use the Blank Form template.

create a blank form

In the form builder, we’ll add fields to our form. To enable Stripe payment in the form, we’ll need the Stripe Credit Card field and a payment items field.

If you’d like, you can add other fields to collect information from your users. For our example, we’ll also add Name, Email, Dropdown Items, and Total fields.

Stripe order form example

3. Enable Stripe Payments

Once you’ve added the fields you’d like to have to your form, you’ll need to allow Stripe payments in the form by going to Payments » Stripe and select Enable Stripe Payments.

Enable Stripe payments in WPForms

The Stripe Credit Card field also requires your form to use AJAX submissions. This is when your form submits without requiring the page to refresh. You can enable this by going to Settings » General and then checking the box labeled Enable AJAX form submission.

ajax form submissions

Once this is all set, don’t forget to save your form.

4. Publish Your Form and Perform the Test

Once you have set up your form, you can test the form on the frontend of your site. To do this without publishing the form to a live page, you can use the form preview option in WPForms, or create a private page or post.

As genuine card information can’t be used in test mode, you can use any test card numbers listed in Stripe’s testing doc.

5. View Test Transactions on Your Stripe Account

Stripe does not send payment receipts in test mode so you won’t receive any Stripe payment notification automatically. To view or send receipts manually, you can check your Stripe Dashboard.

To begin, you’ll need to log into your Stripe account. After logging in, look for the menu on the left and select the Payments option.

Next, near the bottom of the menu select the View test data button.

This will show you an overview of the test payments you’ve received in your Stripe account.

stripe dashboard

If you’d like, you can view more details for an individual payment. To do this, go to the row for that entry and click on the three dots to see more options. Then, select View payment details.

View payment details

In the individual payment details page, you can see more information and options for the specific payment.

To view or send Stripe payment receipts for the test payment, scroll down to Receipt history section to click on View receipt or Send receipt.

Note: When you are done testing, remember to deactivate Test Mode in Stripe before allowing users to submit payment in your form. You can do this by going to WPForms » Settings and the Payments tab, as seen the previous step.

That’s it! You can now test Stripe payments in the forms.

Next, do you want to set up automatic form notifications so you can receive submitted entries in your email? Then, be sure to check out our guide on how to set up form notifications emails.