Why the IP keeps changing
Fly rewrites the source address of a Machine’s outbound IPv4 traffic on the host it runs on. Restart or move the Machine and the address can change; Fly calls these default egress IPs unstable.
Second trap: if the destination has an IPv6 address, your Machine often connects over IPv6. A firewall that only lists your IPv4 then rejects you.
Option 1: Fly static egress IPs
- Allocate a static egress pair for the app in each region it runs in (here Frankfurt). Output from our run, addresses replaced with examples:
$ fly ips allocate-egress --app my-app -r fra Allocated egress IPs for region fra: 203.0.113.42 2001:db8:42::1 Newly-allocated egress IPs may need 5 - 10 minutes to take effect on existing machines.You should see: one IPv4 and one IPv6 address for that region. - List the app’s addresses and send every egress address to the partner, IPv4 and IPv6:
$ fly ips list --app my-app VERSION │ IP │ TYPE │ REGION v4 │ 203.0.113.42 │ egress │ fra v6 │ 2001:db8:42::1 │ egress │ fra - Wait a short moment: new pairs reach existing Machines after a delay, and new Machines may need a moment too, especially during blue-green deploys.
How static egress IPs behave
- They belong to the app and the region, not to one Machine. Running in two regions means two pairs to allowlist.
- As of November 2026 each IPv4 egress address costs $3.60 a month, billed hourly. The IPv6 address is not billed separately.
- They stay until you release them with
fly ips release-egress <ip>, even when Machines are destroyed or redeployed. - Each address supports up to 64 Machines. With several pairs in one region, Machines pick one at random.
Option 2: a dedicated-IP proxy for selected requests
If only one partner API needs a fixed address, leave Fly’s networking alone and send just those requests through your own server. That also gives you one address across several apps, regions and hosting platforms.
- Log in to the client area, open My Services and click your server. Scroll to Use your IP from code, n8n, CI or a browser. Under Add a proxy user, type
flyand click Add.
You should see: a new card namedapp-fly. Names can use letters and digits only, and MazeVPN adds theapp-prefix. - On that card, click Copy next to HTTPS proxy (marked Encrypted). The copied URL contains the password, so paste it only into a secret or environment variable, never into code.
The card of a new proxy user. The eye icon shows the password; Copy copies the full URL with the password. (Server IP replaced with an example.) You should see: a URL likehttps://app-fly:…@203.0.113.42:443, where the address is your server’s IP. - Store the URL as a secret. Quote it so the shell does not touch special characters. By default flyctl deploys the new secret to your Machines; add
--stageto set it without deploying.fly secrets set MAZE_PROXY_URL='https://app-fly:PASSWORD@203.0.113.42:443' --app my-app - In Node.js, pass a proxy dispatcher only to the calls that need the fixed IP; the helper is in the Vercel guide. In Python with requests, see the Heroku guide.
A real test run (November 2026)
We ran this on a new Fly app in Frankfurt with a MazeVPN test server. The secret was set with --stage, which still reaches Machines created afterwards. The Machine printed its normal address first and the static IP through the proxy (addresses replaced with examples):
fly machine run curlimages/curl:latest --app my-app --region fra --restart no \
--entrypoint /bin/sh -- -c 'echo direct=$(curl -s https://ifconfig.me/ip); \
echo proxy=$(curl -s --proxy "$MAZE_PROXY_URL" https://ifconfig.me/ip)'
fly logs --app my-app --no-tail
# output
direct=198.51.100.23 # Fly's shared egress, changes
proxy=203.0.113.42 # your static IPTest from a running Machine
- Open a shell on a Machine with
fly ssh console --app my-app. If curl is installed in your image, run the check:# static egress: direct call curl -s https://ifconfig.me/ip; echo # proxy: through your server curl -s --proxy "$MAZE_PROXY_URL" https://ifconfig.me/ip; echoYou should see: an address fromfly ips listfor static egress, or your server’s IP for the proxy. - If the destination supports IPv6, also check
curl -6 -s https://ifconfig.me/ipand make sure that address is allowlisted, or force IPv4 in your client. - Make one real read-only request to the partner from every region you run in, then remove old allowlist entries.
Official references
Skip the setup
A dedicated IPv4 in 38 cities, usually ready about 3 minutes after payment. Connect devices with WireGuard and apps with an authenticated HTTPS, HTTP, or SOCKS5 proxy. From $9.99/month.