Do you want to allow users to choose between different payment methods on a WordPress form?
When you allow your customers to choose their preferred payment method, you’ll build trust and increase conversions on your website.
In this article, we’ll show you how to allow your users to choose a payment method in your WordPress forms.
Why Offer Multiple Payment Methods in WordPress?
PayPal and credit cards are two popular ways to pay for online purchases. Each has its pros and cons, and your visitors are likely to already have a preference for one or the other.
So, if you’re selling products or services on your WordPress website, or asking for donations, then it is important to allow your visitors to use their preferred payment method.
You don’t need to set up a complete online store with a shopping cart to accept online payments. All you need is a simple online order form with a choice of payment options.
This makes a lot of sense, especially if you’re selling a single product, accepting payments for services, or raising money for a cause or charity.
You will need to enable HTTPS/SSL on your website so that you can accept payments securely. For more details, you can follow our guide on how to get a free SSL certificate for your WordPress site.
That being said, let’s look at how you can offer multiple payment options on your website.
How to Setup a Payment Form in WordPress
WPForms is the best drag and drop form builder plugin for WordPress. It lets you create a simple order form or donation form without the hassle of a full-fledged eCommerce platform or shopping cart plugin.
Upon activation, you need to visit the WPForms » Settings page to enter your license key. You can find this information in your WPForms account area.
Connecting Payment Platforms to WPForms
Next, we’ll connect WPForms with the payment platforms you plan to use. To do this, you need to head over to WPForms » Addons and install the payment addons.
Once there, you need to scroll down to the PayPal Standard Addon and then click on its Install Addon button.
You’ll see a message saying that the addon has been installed and activated, and the text on the button will change to Deactivate.
We’ll set up your PayPal account details later in the tutorial.
You’ll also need to install an addon for accepting credit card payments. WPForms supports Stripe, Square and Authorize.net. For this tutorial, we’ll set up Stripe, but the steps for setting up the other two platforms are similar.
You’ll need to scroll to the Stripe Addon and click on the Install Addon button.
Once the addons have been installed and activated, you’ll need to connect WPForms to your Stripe account.
To do that, head over to WPForms » Settings page and click on the ‘Payments’ tab. After that, you will need to connect your Stripe account by clicking the ‘Connect with Stripe’ button.
On the next screen, you can enter your Stripe email address and click the ‘Next’ button.
Once that is done, Stripe will now ask for your password so that it can log in to your account.
After logging in, you can select your Stripe account and then click the ‘Connect’ button.
Next, you will be redirected back to the WPForms Payments settings tab. To make sure that your account is successfully connected, you can go to the Connection Status settings under Stripe settings.
When you see a green tick mark, it means your Stripe account is now live with WPForms. Go ahead and click the ‘Save’ button to store your settings.
WPForms is now ready to accept credit card payments.
Creating an Order Form with Multiple Payment Methods
Now we’ll create an online order form that can accept both PayPal and credit card payments.
To start, head over to WPForms » Add New page. From here, you need to provide a title for your form and then select the ‘Billing / Order Form’ template.
WPForms will pre-load the form builder with a simple order form with commonly used fields. You can edit any field by clicking it.
You can add new fields from the left column using drag and drop. You’ll need to drag a Multiple Choice field onto the form to allow your customers to select from multiple payment options.
After that, you should drag the Stripe Credit Card field onto the form just underneath the Multiple Choice field.
Next, you need to change the options on the Multiple Choice field to match the payment methods you are offering.
Start by giving the field the label Payment Method. After that, you should name the first two choices PayPal and Credit Card.
You can simply remove the third choice by clicking the red minus – button.
After that, you need to switch the Required option on. This will make sure that users select a payment method before they submit the order form.
Now we need to set up the Stripe Credit Card field, so it is hidden until a user selects it as their payment option. We can achieve that by using WPForms’ conditional logic feature.
You’ll need to click on the Stripe field so that you can edit it. Next, you should click on the Smart Logic tab and then enable conditional logic by clicking the toggle switch to the on position.
You will now see some additional options that allow you to set up rules for the field. You need to make sure that the first option is selected to ‘Show’ and then use the drop down menus so that the remaining fields say ‘Payment is Credit Card’.
Now the Stripe Credit Card field will only be shown after a user selects Credit Card from the Payment Method field.
Enabling Payment Methods for the Order Form
The next step is to enable PayPal and Stripe payments for the order form.
You should first navigate to Payments » PayPal Standard in the WPForms form builder. Once there, you should check the ‘Enable PayPal Standard payments’ box in the right panel.
After that, you should fill in the rest of the fields. Type in your PayPal email address and place the account in Production mode. You also need to configure whether users need to supply a shipping address.
After that, you need to scroll down to the Enable Conditional Logic option and toggle it to the ON position. This will reveal more settings.
You should set the rule to Process the charge if the Payment Method is PayPal.
Next, you need to click on the Stripe section of the Payments tab and then check the ‘Enable Stripe payments’ box.
You can add a payments description and opt to email a receipt if you wish. After that, you need to switch the Enable Conditional Logic toggle to the on position so that you can create a rule for this payment option.
You need to configure the rule to read Process this charge if the Payment Method is Credit Card.
If you’d like to accept recurring subscription payments by credit card, then you can scroll down to the Subscription section and configure it.
Once you are done, you need to click on the Save button at the top and exit the form builder.
Adding the Order Form to Your WordPress Site
Your online order form with multiple payment options is now ready, and you can add it to any WordPress page on your site.
To add your form, simply edit a post or page or create a new one. Then, click on the plus + sign on the right of the page and add a WPForms block in your WordPress editor.
After that, you need to click on the dropdown menu in WPForms block and select your order form.
You can now save or publish your page and click on the preview button to see your form in action.
We hope this tutorial helped you learn how to allow users to choose a payment method on your WordPress form.