Skip to main content
Easy Digital Downloads Documentation
Documentation, Reference Materials, and Tutorials for Easy Digital Downloads

Stripe – Setup Documentation

The following setup documentation is for the Stripe payment gateway. Stripe Standard is included with the free version of Easy Digital Downloads. Stripe Pro payment gateway extension is a optional extension that adds support for Preapproved Payments and removes the fee added to Stripe Standard payments.

Configuring Stripe

In order to use the Stripe payment gateway, you must first have a Stripe account. It’s free to create a Stripe account, and testing it is also free. Also, see Stripe’s business information requirements.

(Optional Step) Install or Upgrade to Stripe Pro

Stripe Pro is enabled as soon as the Stripe Pro extension is installed and activated.

If you are currently using the free version of Stripe in EDD (i.e. Stripe Standard) and want to upgrade to Stripe Pro, there are no additional steps required. Once the Stripe Pro plugin is installed and activated, you will not be charged the 2% additional fee going forward.
The 2% fee is added only while using the free version of Stripe in EDD.

1. Enable the Stripe Payment Gateway

Go to  WordPress admin → Downloads → Settings → Payments, then enable the Stripe payment gateway.

2. Connect with Stripe

Select the Stripe sub-tab within the Payment Gateways tab, then click the Connect with Stripe button.

This will take you to the Stripe website where you can log into your existing account if you have one or create a new account if you do not.

3. Webhook configuration

The Stripe payment gateway can automatically detect refunded purchases in your Stripe account. When a refund is detected, the corresponding purchase in EDD is also marked as refunded.

EDD creates a webhook for you, and you simply need to tell Stripe where it is. If webhooks are not configured properly or are blocked by a plugin or configuration of your site, this automatic refund detection will not function.

1. To add the appropriate webhook endpoints, in your Stripe dashboard go to  Developers → Webhooks (direct link). We recommend creating two webhook endpoints: one for test mode and one for live mode. If you create both, you’ll need to repeat the below process after toggling modes.

2. Click +  Add Endpoint

3. Add the following URL:

https://example.com/?edd-listener=stripe

Note: Replace “example.com” with your actual site URL. The exact URL you need to enter can be found in your WP admin under Downloads → Settings → Payments → Stripe.

4. “Listen to events on Connected accounts” settings should be disabled (unchecked).

5. Version should be set to “Latest API version”.

6. Select the following events:

charge.succeeded
charge.refunded
customer.subscription.deleted
customer.subscription.updated
customer.subscription.created
invoice.payment_failed
invoice.payment_succeeded
review.opened
review.closed

Example of how the Endpoint settings should be configured:

After you add the endpoint you will see the new URL listed in the webhooks settings.

Note: Your webhooks won’t work out of the box in a local development environment like Vagrant, WAMP, MAMP, Desktop Server, or Local by Flywheel. These are typically non-publicly accessible IP addresses and Stripe can’t reach them.  

4. Recurring Payments Integration (Required to sell subscriptions)

The Stripe payment gateway has complete support for the Recurring Payments extension. See the Recurring Payments Stripe setup documentation for configuration instructions.

Additional Settings / Features

There are additional settings and features detailed below.

Billing Address Display

This drop-down field will allow you to select which billing details are collected. There are three options:

  • Full address – This will result in a complete address form with street, city, country, state / province, and zip / postal code being displayed.
  • Zip / Postal Code and Country only – This will result in a simplified address form being displayed that asks only for zip / postal code and country.
  • No address fields – This will result in no address fields being displayed.
Billing address notes
  • Taxes note: if you have taxes enabled, only the full address option may be used as those fields are required for accurately calculating taxation amounts.
  • Fraud note: collecting a full billing address can help reduce fraudulent charges. It is recommended that minimum zip / postal code and country be collected.
Statement Descriptor

A short description of the purchase will show up on the bank/card statement alongside the charge. By default, the statement descriptor will show up as your product name. If the customer purchased Basic Product, that’s what will show up on the bank statement.

Note: only 22 characters are allowed for statement descriptors. So if your product name is too long, it will be truncated. 

This (optional) Statement Descriptor field will override the statement descriptor for all products. If left blank, product titles (including price option labels) are used instead.

Note, when a product is configured as a subscription using our Recurring Payments extension, the behavior is slightly different. See the Recurring Payments with Stripe documentation for details.

Apple Pay / Google Pay (Express Checkout)

See Stripe – Express Checkout (Apple Pay / Google Pay) for details on how to configure Express Checkout options.

Show Previously Used Cards

This saves card information so returning customers do not have to re-enter payment details. Note, card data is securely stored on Stripe’s servers, not on your site.

Preapproved Payments (Stripe Pro Feature)

Check this if you would like to collect payment information but not collect the payment until a later date. Typically, this option is used for pre-orders. To process the payment and provide access to your download(s), click “Process” in the “Status” column when viewing the Payment history list. 
Note that most typical stores will not need this option.

Note: When enabled, this affects all Stripe payments for all products.

Prepaid Cards
Enable to allow prepaid cards as valid payment methods.
Split Credit Card Fields
By default, the card number, expiration, and CVC use the same field. Enabling this setting splits up these fields.

Combined field (default):

Combined credit card fields (default)

Split fields:

Restrict Stripe Assets

This setting prevents Stripe assets from loading on every page. Most sites should not enable this setting. Stripe advises that their JavaScript library be loaded on every page to take advantage of their advanced fraud detection rules. If you are not concerned with this, enable this setting to only load the JavaScript when necessary.

Buy Now

If you meet the Buy Now requirement, this will allow customers to checkout via a popup modal. For details on how this works, see our Buy Now Buttons documentation.

Buy Now

If you meet the Buy Now requirement, this will allow customers to checkout via a popup modal. For details on how this works, see our Buy Now Buttons documentation.

System Requirements

The official Stripe PHP library included in Easy Digital Downloads requires PHP 5.6 or higher.


Testing Stripe

You can test Stripe in Test Mode which allows you tryout the payment process without using a real credit card. Stripe offers test cards for this process (see below).

1. Enable EDD Test Mode

Navigate to Downloads → Settings → Payment Gatewaysand enable Test Mode.

2. Connect with Stripe

Select the Stripe sub-tab within the Payment Gateways tab, then click the Connect with Stripe button. If you’ve already connected to Stripe with Test Mode disabled, you will have to connect again in Test mode. Once you are connected in both Live and Test Mode, you do not need to re-connect when switching back and forth.

This will take you to the Stripe website where you can log into your existing account if you have one or create a new account if you do not.

Stripe Temporary Test Account

Stripe offers a temporary test account by clicking “Skip this form”. We do NOT recommend this option as it’s best to use an actual account, the same account as your live account. This allows you to configure webhooks and ApplyPay once for both Live and Test Mode. Also, if you are testing Recurring Payments, renewals will not work with a temporary test account. 

3. Testing a Purchase

Now in test mode, add a product to your cart and proceed to checkout.

You can use the card number  4242424242424242 with any CVC and a valid expiration date (any date in the future).

Testing Express Checkout (Apple Pay / Google Pay)

See Stripe – Express Checkout (Apple Pay / Google Pay) for details on testing Express Checkout.

Additional Resources

See Stripe Testing for more test card number and additional testing options.


FAQ

Q: How do I accept Discover, JCB, and Diner’s Club with Stripe?

A: When using the Stripe Payment Gateway, the accepted forms of payment can change depending on the currency your store is configured with. Below is a table explaining which payment methods are accepted for currencies:

 USDNon-USD
Visa
Mastercard
American Express
Discover 
Diner’s Club 
JCB 

You can read more about the currencies accepted by Stripe in their documentation.

Q: How do I remove the additional 2% fee from my Stripe transactions?

A: You will not incur an additional 2% fee from your Stripe transactions if you purchase a license to an EDD Extended (or higher) Pass or the individual Stripe Pro extension. The Stripe Pro extension must also be installed and activated.

Q: What features does the Stripe Pro extension have that the free version of Stripe in EDD does not?

A: Currently, the Stripe Pro extension adds the ability to accept pre-approved payments.

Q: Does the 2% fee apply to PayPal or Amazon Payments?

A: No, the 2% fee only applies to transactions processed through Stripe when using the free version of Stripe.

Q: Does the 2% fee apply to recurring Stripe transactions?

A: No, the 2% fee only applies to the initial transaction. If you’ve installed both our Stripe Pro and Recurring Payments extensions together (both included in our Extended (or higher) Pass, you will not incur this additional initial transaction 2% fee.

Q: Can I connect to my Stripe account manually using my Stripe API keys?

A: In order to provide the best experience, we only offer Stripe Connect as for integrating with Stripe.

Q: Can I downgrade from Stripe Pro to Stripe Standard?

A: Yes, you can deactivate and delete the Stripe Pro extension and Stripe Standard will automatically take over. Log into your account to cancel your Stripe Pro subscription.