IP whitelisting
Paga only accepts API requests from IP addresses you’ve registered in your business portal. Add your servers’ addresses before your first call, in Sandbox and in Live.
Every API needs this. Collect, Direct Debit, the Business API and every other Paga API. Requests from an address that isn’t on your list are rejected, even with valid keys.
Add an IP address
Find your server’s public IP address
Run this on the server that will call Paga, not on your laptop:
curl https://ifconfig.meLog in to the dashboard for your environment
Open the IP Whitelist tab
Go to Developer Tools → IP Whitelist.
Add the address and save
Add each server that calls Paga’s APIs. Repeat in the other environment when you’re ready.
Allow Paga’s IP addresses on your server
Registering your IP addresses controls who can call Paga. Do the same in reverse for what Paga sends you: accept callbacks only from Paga, and reject everything else.
| Environment | Paga’s IP address | Callbacks from |
|---|---|---|
| Live | 51.124.69.198 | Paga’s Live servers |
| Sandbox | 51.136.123.148 | Paga’s test servers |
These addresses are the same for every Paga API and every callback: Collect, Direct Debit, Checkout, the Business API and notifications.
Allow only these addresses
On every URL that receives Paga’s callbacks, such as your callback URL, status callback URL and biller endpoints, accept requests from these addresses only.
Reject the rest, and log it
Return a 403 for any other address and record it. Don’t explain why in the response.
Check the real connection address
Apply the rule at your firewall, load balancer or WAF. Don’t trust an X-Forwarded-For header unless your own proxy sets it.
Keep verifying the hash
The IP rule is a second layer, not a replacement. Verify every callback’s hash as well. See Authentication.
Keep Sandbox and Live apart
Allow the Sandbox address on your test server and the Live address on production only.
Plan for changes
We email you, with a timeline, before an address changes. Add the new one before the date, and remove the old one afterwards.
location /webhooks/paga {
allow 51.124.69.198; # Paga Live. Use 51.136.123.148 on your test server
deny all;
proxy_pass http://your_app;
}
# Behind a load balancer? Restore the real client address first (Nginx real_ip module).Good to know
Use a fixed address
Cloud servers can change IP when restarted. Use a static IP or a NAT gateway so your address stays the same.
Sandbox and Live are separate
Addresses added in one environment don’t carry over to the other.
Testing from your laptop
Home and office connections often change address. Test from a server with a fixed IP instead.
Moving servers?
Add the new address before you switch traffic, then remove the old one.
Requests failing after a deploy?Check your server’s IP hasn’t changed. A new address that isn’t on the list is the most common cause of sudden API rejections.
Need help? We’re here 24/7
Talk to our support team any time, or ask questions in the developer community.
Updated 5 days ago

