> ## Documentation Index
> Fetch the complete documentation index at: https://docs.partnero.com/llms.txt
> Use this file to discover all available pages before exploring further.

# PayPal Links & Buttons integration

This article covers how to integrate Partnero affiliate tracking when you use **PayPal Pay Links and Buttons to accept payments on your website.**

*To learn about integrating PayPal Mass Pay for automated payouts, [click here](/integrations/paypal).*

***

### How does the PayPal Links & Buttons integration work?

There are two main parts to the integration:

1. Creating a referred customer on Partnero.
2. Tracking the customer's purchases.

We'll cover both in this article. These instructions can also be found on your Partnero account, under **Integration** > **Guides** tab > **PayPal Links & Buttons**:<img src="https://mintcdn.com/partnero/zRPK-G3bX1rzMUwg/images/articles/paypal-links-buttons-integration/dbfc91a1.webp?fit=max&auto=format&n=zRPK-G3bX1rzMUwg&q=85&s=f4defbc8fa525a1417d15ae8641dbafd" alt="" width="2872" height="1490" data-path="images/articles/paypal-links-buttons-integration/dbfc91a1.webp" />

***

### Step 1: Start tracking website visitors

To track visitors on your website, you need to install the PartneroJS snippet as custom code.

#### Install the PartneroJS Snippet

1. On Partnero, go to **Integration** > **Guides** tab > **PayPal Links & Buttons**. Click **Instructions**.
2. Copy the PartneroJS snippet:<img src="https://mintcdn.com/partnero/zRPK-G3bX1rzMUwg/images/articles/paypal-links-buttons-integration/cfbb0afb.webp?fit=max&auto=format&n=zRPK-G3bX1rzMUwg&q=85&s=532d76d4b39bc60175debda2ca38c439" alt="" width="2874" height="1500" data-path="images/articles/paypal-links-buttons-integration/cfbb0afb.webp" />
3. Pase the script before the closing *\</head>* tag in the HTML code of your website.

***

### Step 2: Update PayPal settings

Edit the following settings on your PayPal account:

1. Go to **Account Settings** from the upper right corner:<img src="https://mintcdn.com/partnero/zRPK-G3bX1rzMUwg/images/articles/paypal-links-buttons-integration/4d070081.webp?fit=max&auto=format&n=zRPK-G3bX1rzMUwg&q=85&s=e9acc0c8a84d5945e06a1d35bc51e371" alt="" width="2874" height="1466" data-path="images/articles/paypal-links-buttons-integration/4d070081.webp" />
2. Go to **Website payments** section under Products & services:<img src="https://mintcdn.com/partnero/zRPK-G3bX1rzMUwg/images/articles/paypal-links-buttons-integration/1d776169.webp?fit=max&auto=format&n=zRPK-G3bX1rzMUwg&q=85&s=e18a800d11f029f674644f958c1209bc" alt="" width="2864" height="1462" data-path="images/articles/paypal-links-buttons-integration/1d776169.webp" />
3. Locate **Website preferences** and click **Update**:<img src="https://mintcdn.com/partnero/zRPK-G3bX1rzMUwg/images/articles/paypal-links-buttons-integration/f282dc24.webp?fit=max&auto=format&n=zRPK-G3bX1rzMUwg&q=85&s=4c81f28ee2cda1a541c803929cea7034" alt="" width="2874" height="1498" data-path="images/articles/paypal-links-buttons-integration/f282dc24.webp" />
4. Switch **Auto return** to "On" and enter the URL of the return/thank you page:<img src="https://mintcdn.com/partnero/zRPK-G3bX1rzMUwg/images/articles/paypal-links-buttons-integration/a435dcff.webp?fit=max&auto=format&n=zRPK-G3bX1rzMUwg&q=85&s=c9ce501f8ebd7650fa762b959c49e61a" alt="" width="2878" height="1494" data-path="images/articles/paypal-links-buttons-integration/a435dcff.webp" />
5. Switch **Payment data transfer** to "On":<img src="https://mintcdn.com/partnero/zRPK-G3bX1rzMUwg/images/articles/paypal-links-buttons-integration/1d284e54.webp?fit=max&auto=format&n=zRPK-G3bX1rzMUwg&q=85&s=ae49b8f10bec8b2d071ad48b1fef042c" alt="" width="2872" height="1490" data-path="images/articles/paypal-links-buttons-integration/1d284e54.webp" />

***

### Step 3: Set up sales tracking on the return page

Here's how to set up order tracking during checkout:

1. On Partnero, copy the sales tracking code from the integration guide:<img src="https://mintcdn.com/partnero/zRPK-G3bX1rzMUwg/images/articles/paypal-links-buttons-integration/851432b1.webp?fit=max&auto=format&n=zRPK-G3bX1rzMUwg&q=85&s=04bd30eff0aa4fedc9032d70764528c0" alt="" width="2874" height="1496" data-path="images/articles/paypal-links-buttons-integration/851432b1.webp" />
2. Paste the script on the returning/thank you page. It's essential to place this script at the bottom of the page, directly above the closing *\</body>* tag for optimal functionality.

***

### Step 4: Enable transaction creation via JS

For this integration method to work, transaction creation via JavaScript must be enabled on your Partnero account. To do that:

1. On your Partnero account, go to **Integration** > **Security** tab.<img src="https://mintcdn.com/partnero/zRPK-G3bX1rzMUwg/images/articles/paypal-links-buttons-integration/cb4e7319.webp?fit=max&auto=format&n=zRPK-G3bX1rzMUwg&q=85&s=b3facb592eda2ec47cfa35652b1565cb" alt="" width="2874" height="1530" data-path="images/articles/paypal-links-buttons-integration/cb4e7319.webp" />
2. Scroll down to **Secure JS calls**. Toggle to enable transaction creation:<img src="https://mintcdn.com/partnero/zRPK-G3bX1rzMUwg/images/articles/paypal-links-buttons-integration/c80c44f9.webp?fit=max&auto=format&n=zRPK-G3bX1rzMUwg&q=85&s=823a954793eca136fad569e3d2c5d9e0" alt="" width="2876" height="1514" data-path="images/articles/paypal-links-buttons-integration/c80c44f9.webp" />
3. Click **Update**.

***

Your integration is now complete! We strongly recommend testing the integration by purchasing through an affiliate link.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.