WooCommerce PayPal Digital Goods Gateway
Set up a PayPal Business Account
If you do not already have a PayPal account:
- Go to the PayPal Website and sign up for a Business account.
- Ensure that it’s configured for Digital Goods by visiting the PayPal Digital Goods sign-up page
- Click the Get Started button and follow the business setup steps.
Obtain your PayPal API Credentials
You can now link your WooCommerce store to PayPal with API credentials.
To connect your store:
- Go to PayPal to get your PayPal API credentials.
- Copy the API credentials of the Sandbox account, if you plan to use PayPal Sandbox to test payments before going live. You can log into your Sandbox account here.
- Copy the API credentials for your live account for setup.
- Download the .zip file from your WooCommerce.com account.
- Go to: WordPress Admin > Plugins > Add New to upload the file you downloaded with Choose File.
- Activate the extension.
More information at:.
Set up and configuration
With your API Credentials, you can configure the PayPal Digital Goods extension.
- Go to WooCommerce > Settings > Payments > PayPal Digital Goods.
- Enter a Title and Description shown to customers during checkout.
- Add your PayPal API credentials from above.
- Tick the checkbox for PayPal Sandbox if testing payments. Untick if going live.
- Tick the checkbox for Enable logging, which is helpful for troubleshooting purposes.
- Click Save.
Can I sell physical products with PayPal Digital Goods?
Yes. Although PayPal restricts their digital goods in-context payment flow of the sale of physical items, the WooCommerce PayPal Digital Goods extension has been developed in a way that allows you to also sell physical goods.
You do not receive the benefits of address validation and separate shipping line items on payment terms, but you do get to offer a smoother payment flow for your customers.
Can I sell subscriptions with PayPal Digital Goods?
PayPal Digital Goods can be used to sell subscriptions with WooCommerce Subscriptions (separate purchase).
To sell subscriptions, there is nothing extra to configure. Purchase and install the WooCommerce Subscriptions extension, and ensure both extensions are activated. When PayPal Digital Goods is enabled, it appears as a payment option for orders containing subscription products.
Your customers can purchase, suspend and cancel their subscriptions with PayPal right from your WooCommerce store.
How do I test with the Sandbox?
To test the PayPal Digital Goods WooCommerce extension with PayPal Sandbox, you need to create a correctly configured PayPal Sandbox account.
PayPal makes this more difficult than it should be and doesn’t publish instructions, but you can find instructions for configuring a Sandbox Account here.
Can customers pay with a credit card or do they need a PayPal account?
When purchasing products, customers can optionally choose to Buy as a Guest. When checking out as a guest, the customer does not need a PayPal account and can make the purchase with their credit card.
PayPal does not allow subscriptions to be purchased with a guest account. Subscriptions need to be tied to an account.
Once a PayPal account is set up for Digital Goods, can it only process digital goods?
A PayPal account set up for Digital Goods can sell any type of item. The special configuration required for PayPal’s Digital Goods solutions is to provide you with discounted fees for micro-payments.
You can continue to accept payments via PayPal Standard or PayPal Express Checkout.
What does PayPal consider a “Digital Good” vs. a regular physical purchase?
The main difference for PayPal is that the transaction cannot include a separate shipping amount.
When the WooCommerce extension communicates with PayPal, it notifies PayPal that the transaction is for a digital good and combines the shipping amount (if any) into one total cart price. This is a workaround for selling both physical and digital goods with the PayPal Digital Goods solution, as explained in more detail in this FAQ.
Why do I see a “Security header is not valid” error?
On occasion when setting up PayPal Digital Goods and attempting to check out for the first time, store managers encounter the following error:
Calling PayPal with action SetExpressCheckout has Failed: Security header is not valid
This indicates that your API credentials are not valid for the transaction. Invalid API credentials can be caused by:
- Using sandbox API credentials for live transactions (or vice versa);
- Using API credentials for an account that has not been correctly set up to use PayPal Digital Goods;
- Copying and pasting the incorrect API credentials — For example, the API signature can include a period (.), which means double-clicking it will only copy part of the signature.
Why are subscription payments charged late?
When creating a subscription with PayPal, PayPal takes control of the schedule for charging recurring payments payments. PayPal also batch-processes payments, so they may not process payments on the exact date they are due. Instead PayPal processes a payment within 24 hours of a due date.
For example, if a recurring payment is due at 2:00 pm on 1 July, PayPal may charge that payment anytime between 12:00am and 11:59pm on 1 July.
Why do subscriptions have a trial period and initial payment?
When purchasing a subscription with PayPal Digital Goods version 2.4 or newer, you may notice that terms displayed in PayPal include a free trial and initial amount, even when the subscription does not include a free trial.
For example, below are the payment details displayed in PayPal for a $25 per month subscription. The first image shows the details created with the PayPal Digital Goods extension prior to version 2.4. The second show the details created with version 2.4.
Despite both being $25 per month subscription, payment details for the subscriptions differ.
- The details for the subscription created prior to PayPal Digital Goods version 2.4 includes only a regular recurring payment of $25 on a monthly cycle.
- The subscription created with PayPal Digital Goods version 2.4 includes an initial payment equal to $25 and then one trial period of $0 for one monthly cycle.
The amount you receive and the amount charged to your customer is exactly the same with both sets of details, but there are important benefits in creating the subscription using an initial payment:
- Customers only need to wait until the initial payment is successfully processed before their subscription is activated. This almost always is less than a minute. Without using an initial payment, customers need to wait until PayPal charged the first payment on the subscription’s start date, which could be up to 24 hours and depends on when PayPal charges the payment (recurring payments are charged in batches).
- You are guaranteed to receive the first payment before the subscription is activated.
- Customers can reliably sign up for subscriptions, regardless of your store’s timezone.
Unfortunately, splitting subscription terms can be confusing for your customer. PayPal does not provide another method to ensure the first payment is charged immediately.
How can I change the language used on PayPal pages to match the language on my store?
PayPal Digital Goods sends your site’s language to PayPal to request it uses the same language on PayPal pages. However, PayPal does not always honor this request and sometimes defaults to English or another language.
PayPal Digital Goods was written in line with the PayPal documentation and choosing a locale, which suggests it is possible to force the language. But after reporting issues with unexpected languages to PayPal Merchant Technical Services, they advised that ignoring the requested language is sometimes the default behavior and can’t be changed.
Why does PayPal only show two items?
When reviewing items at PayPal, you may think that details of only two items were sent to PayPal as it appears only two items are displayed.
However, PayPal hides additional items and has not yet updated its user interface to account for the invisible scrollbars that newer versions of Chrome, Firefox and other browsers now use.
To view details of all items in an order, you need to hover over the item list and scroll, as presented in the video below. We have no control over this user interface, and it is up to PayPal to fix the issue.
Is PayPal Digital Goods responsive? Does it work on iOS?
On small screens and all Apple iOS devices, PayPal Digital Goods for WooCommerce uses PayPal’s Mobile Checkout flow.
This flow provides a mobile optimized experience for customers to make it easier to check out, and also works around bugs in PayPal’s Digital Goods code that affects the Safari browser on iOS devices.
Why don’t refunds work for subscription payments?
For refunds to work for Subscription payments, ensure that the PayPal IPN is set up and working. To process a refund, the PayPal Digital Goods extension requires the transaction ID. For Subscription payments, PayPal only sends the transaction ID via IPN.
To configure the IPN on your PayPal account, go to the PayPal Standard Notification URL setup guide.
Once you have the IPN set up correctly, you can see the transaction ID as a clickable link on orders created to record subscription payments, including the initial order and renewal orders.
Click here to download WooCommerce PayPal Digital Goods Gateway