Turning off the public IP: making a server private-only
1. Check these first
Once the public IP is off you cannot connect to the server directly from the internet, and (if NAT is off on the VPC gateway) the server cannot reach the internet either.
- The server must have at least one
readyprivate network card (attach guide). - If the server must reach the internet (updates, package installs, external APIs), enable the VPC gateway with NAT on the VPC (VPC gateway guide). With NAT off you must give an extra confirmation to proceed.
- If you have an additional IPv4, remove it first; turning off is refused on a server with additional IPv4s.
- Decide how you will connect: from another server in the same VPC or through a port forward on the gateway. The web console on the service page works independently of the network and is always available.
- On older servers without the guest agent, turning off is refused (the routing cannot be applied inside the server); newly created servers are fine.
2. Turning off from the panel
- My Services → your server → Private network (VPC) tool.
- Choose Turn off public IP.
- To confirm, type the server's current IP address and confirm.
The operation moves the server's default route to the gateway in the private network, then disconnects the public network card. The IP address stays reserved for your server.
While it is off: the only private NIC cannot be removed, the operating system cannot be reinstalled, additional IPv4s cannot be added and the VPC gateway cannot be turned off.
3. Turning back on
In the Private network (VPC) tool choose Turn on public IP. The same IP address returns to the server.
4. Command line and API
gyro server public-ip get 12345
gyro server public-ip off 12345 --confirm-ip <current-IP>
gyro server public-ip on 12345
curl -X DELETE https://www.gyrohosting.com/api/v1/client/cloud/servers/12345/public-ip \
-H "Authorization: Bearer $GYRO_TOKEN" -H "Content-Type: application/json" \
-d '{"confirm_ip":"<current-IP>"}'
The operation returns 202. To turn off while gateway NAT is off, add "allow_no_egress": true to the request (the server will not be able to reach the internet).
| Error | Meaning |
|---|---|
confirm_mismatch |
The IP you typed does not match the server's IP. |
extra_ips |
Remove the additional IPv4 addresses first. |
no_private_network |
There is no ready private network card. |
no_egress |
Gateway NAT is off; confirm with allow_no_egress if you do not need egress. |
already_off / already_on |
Already in the requested state. |
5. Good to know
- Network Firewall rules are for the public IP; they are not applied while it is off and come back when you turn it on again.
- If you use the VPC gateway for NAT, the gateway fee applies separately (about TRY 277.79 per month (4.99 €), metered hourly from prepaid balance).
Next step
Thanks for your feedback!
