PayPal F&F IPN Forwarding
Create a Cloudflare Worker to forward PayPal Friends & Family IPN requests safely to SellAuth.
Overview
PayPal may block or filter direct IPN forwarding links that point to SellAuth.com. To ensure the safety of your PayPal account & reliable invoice processing, you can route IPN requests through your own Cloudflare Worker, using your own domain or a workers.dev subdomain.
This setup is only required for PayPal Friends & Family payments.
Step-by-Step Guide
1: Create a Cloudflare Worker
- Log in at https://dash.cloudflare.com
- Select your Cloudflare account
- In the sidebar go to Build → Compute & AI → Workers & Pages
- Click Create application
- Under Workers, choose Create Worker
- Select Start with Hello World and click Get started
- Click Deploy
- After deployment, click Edit code
2: Replace the code with the IPN forwarder
Delete everything and paste:
export default {
async fetch(request) {
if (request.method !== 'POST') {
return new Response('Only POST allowed', { status: 405 });
}
const body = await request.text();
const targetUrl = 'https://sellauth.com/invoice/paypalff/webhook';
try {
const upstreamResponse = await fetch(targetUrl, {
method: 'POST',
headers: {
'Content-Type': 'application/x-www-form-urlencoded'
},
body
});
const responseBody = await upstreamResponse.text();
return new Response(responseBody, {
status: upstreamResponse.status,
headers: upstreamResponse.headers
});
} catch (err) {
return new Response('Forwarding error', { status: 500 });
}
}
};This Worker forwards the raw IPN body to SellAuth and mirrors the response so PayPal retries automatically if something fails.
3: Deploy and copy your Worker URL
Click Deploy again. Cloudflare will give you a URL like:
https://your-worker.yourname.workers.devThis is your IPN URL. Copy it.
3.a (Optional): Use your own domain instead of workers.dev
If you prefer to use your own domain:
- In Cloudflare dashboard go to Workers & Pages → Settings → Domains & Routes
- Click Add
- Choose Custom domain
- Enter the path you want, e.g.:
https://yourdomain.com/paypal-ipn - Select the Worker you created
Now you can use https://yourdomain.com/paypal-ipn as your IPN URL.
4: Add your Worker URL to PayPal
- Go to: https://www.paypal.com/merchantnotification/ipn/preference
- Click Choose IPN Settings
- Paste your Worker or custom domain URL
- Enable IPN
- Save
You're done!
Your PayPal Friends & Family IPNs will now route through your own Cloudflare Worker, avoiding PayPal filters while still reaching SellAuth reliably.