WPForms Documentation

Documentation, Reference Materials and Tutorials for WPForms

How to Install and Use the PayPal Addon with WPForms

Would you like to collect PayPal payments on your WordPress site? WPForms makes is super easy to integrate PayPal into your forms for order form payments, donations, and more.

In this tutorial, we will show you how to install and use the PayPal addon with WPForms.

  1. Install the PayPal Addon and Create a Form
  2. Add PayPal Payments to Your Forms
  3. (Optional) Set Up Conditional Logic for Payments
  4. Frequently Asked Questions
Requirements: You will need a Pro license level or higher to access the PayPal addon.

1. Install the PayPal Addon and Create a Form

Before we get started, be sure to install and activate the WPForms plugin on your WordPress site.

Once WPForms is installed, you can also go ahead and install the PayPal addon.

With the PayPal addon installed and activated, we’re ready to add PayPal to a form. To do this, create a new form or edit an existing form.

For this example, we’ll create a new form using the Billing / Order Form template. However, you can start with any form you’d like.

Create a new order form

By default, the Billing / Order form template comes with the fields that you’d most often want in a payment form. If you’d prefer to include less fields, however, PayPal needs only one field to work properly: an items field (which could be a Single Item, Multiple Items, or Dropdown Items field).

Even with more than one items field, a Total field is not required for PayPal to work. However, including a Total can be helpful for users to easily see how much they’ll be paying.

Note: When using PayPal, a Credit Card field should not be used. All sensitive payment details will be collected on PayPal’s site, after the form is submitted.

2. Add PayPal Payments to Your Forms

Now that your form is created, the next step is to connect it to PayPal.

With the form builder still open, go to Payments » PayPal Standard. Here, you’ll need to check the box labeled Enable PayPal Standard payments.

Enable PayPal payments for a form

Here are the additional PayPal settings to fill out:

  • PayPal Email Address: The email for your PayPal account, where payment will be sent
  • Mode: Options are Production or Test / Sandbox
  • Payment Type: Options are Products and Services or Donation
  • Cancel URL: If users don’t complete payment on PayPal, this is the URL they’ll be redirected to
  • Shipping: If you’re shipping a product to the user, you can choose to ask for and require an address field during PayPal’s checkout process
For more details on Test / Sandbox mode in PayPal, check out our tutorial on testing PayPal payments.

Additionally, there are two checkbox options at the bottom of these settings. The first is Don’t ask buyer to include a note with payment. If you don’t need users to add a note in the PayPal checkout, you can check this box to disable it.

The second checkbox is to enable conditional logic. This is useful if you’d like to let your users choose between paying with Stripe or PayPal in your form.

When you’re ready, be sure to click on the Save button to store your payment settings.

3. (Optional) Set Up Conditional Logic for Payments

WPForms’ PayPal addon settings also include the option to set up conditional logic. Conditional logic allows you to create “smart forms”, automatically changing content or behavior in the form based on a user’s selections.

There are many ways you can use conditional logic with PayPal payments, for example:

Note: For general information on creating smart forms, be sure to check out our guide to conditional logic.

To set up conditional logic for PayPal payments, you’ll need to open the form builder and go to Payments » PayPal Standard. Under the options you set up earlier, check the box labeled Enable conditional logic.

Enable conditional logic in WPForms PayPal addon

Once this box is checked, some additional options will appear. Within these options, you’ll be able to set your rule(s) about when the user should be sent to PayPal to complete the payment process.

Conditional logic settings in WPForms PayPal addon

The options will include:

  • Process: Determine what should happen if the conditions that you set up are met (options include Process and Don’t Process).
  • Select Field: Choose the field within your form where you’d like to apply this rule.
  • is: Choose the type of comparison you’d like to use (options include is, is not, empty, not empty, contains, does not contain, starts with, ends with, greater than, and less than).
  • Select Choice: Determine what value you’d like the field to contain in order for this condition to apply.

As an example, let’s set up some logic to only run a PayPal payment if the user chooses to sign up for our workshop.

First, we’ll add a Dropdown Items field that will be used in our conditional logic rule. In this field, we’ll let users choose whether or not they’d like to sign up for the workshop.

Field setup for PayPal conditional logic example

After setting up this field and going to Payments » PayPal Standard, we’ll check the box to Enable conditional logic.

We’ll only need to process a payment if they do choose to sign up. To configure the rule for this, we’ll set the dropdowns to read: Process this charge if Would you like to sign up for our workshop? is set to Yes, sign me up!

PayPal conditional logic example

Now when a user submits this form, they’ll only be taken to PayPal if they choose to sign up for our workshop.

Note: Before launching your payment form, we recommend running through our form testing checklist.

Frequently Asked Questions

How do I test PayPal payments in my forms?
The best way to test out your forms is to submit an entry and follow the same steps as your users. We recommend setting up PayPal’s Test Mode before adding your form to a live page, which allows you to test transactions before accepting actual payments.

What happens when a PayPal payment form is submitted?
When a user submits a form with PayPal integration, they will immediately be taken to the PayPal website to complete payment.

At the same time, the form’s notification emails will be sent as soon as the form is submitted.

How do I know when the user completes their payment on PayPal’s site?
Until the PayPal payment is completed, the Entries page will display a Pending status for that entry. Once payment has been made, this status will change to read Completed.

Pending orders for PayPal submissions

That’s it! You’re now able to add PayPal payments in WPForms.

Would you also like to send different notifications to your users based on their selections in the form? Check out our tutorial on conditional notification emails for all the details.

Changelog

1.1.2 (2018-11-12)

  • Fixed: Processing empty payments.

1.1.1 (2018-03-15)

  • Changed: IPN callback URLs to new URLs PayPal recommends (previous ones are being deprecated/removed).
  • Changed: Processing hook order (decreased priority) to avoid conflicts with the User Registration addon.

1.1.0 (2017-09-27)

  • Added: Donation payments include description from payment items
  • Changed: All HTTP requests now validate target sites SSL certificates with WP bundled certificates (since 3.7)
  • Fixed: Email validation issue by converting all email addresses to lowercase first

1.0.9 (2017-01-17)

  • Added: New hook for completed transactions, wpforms_paypal_standard_process_complete

1.0.8 (2016-12-08)

  • Added: Support for Dropdown Items payment field

1.0.7 (2016-08-25)

  • Added: Expanded support for additional currencies
  • Changed: Removed setting to disable IPN verification
  • Changed: Improved IPN verification
  • Fixed: Localization issues/bugs

1.0.6 (2016-08-04)

  • Changed: Multiple payment items now also include label of selected choice in item description
  • Changed: PayPal BN code

1.0.5 (2016-07-07)

  • Added: Conditional logic for payments
  • Changed: Improved error logging

1.0.4 (2016-06-23)

  • Changed: Prevent plugin from running if WPForms Pro is not activated

1.0.3 (2016-03-28)

  • Changed: IPN setting has been moved to the new "Payments" settings tab

1.0.2 (2016-03-16)

  • Fixed: Issue with donation transaction types

1.0.1 (2016-03-16)

  • Fixed: Issue posting to PayPal due to incorrect URL

1.0.0 (2016-03-11)

  • Initial release.