Technical Tip: How to identify the Public IP when FortiGate wan interface has private IP address
| Description | The articles discuss how to identify the public IP address when the FortiGate receives a private IP address via DHCP/PPPoE or when it is manually configured with a private IP address. |
| Scope | FortiGate. |
| Solution | The FortiGate has a private IP address on the WAN interface. In this case, port 1 is configured as the WAN interface and has a private IP address.
To identify the public IP, use the command:
diagnose sys wan ipify port1
This is particularly helpful in setups where the FortiGate is behind another NAT device, such as an ISP modem.
diagnose sys wan ipify port1 Public/WAN IP: xx.xx.xx.xx
On the FortiOS GUI, navigate to Dashboard -> Status, and the public IP can be seen in the system information widget.
Note: Due to security reasons, the Public/WAN IP is hidden, but in place of xx.xx.xx.xx it will show the public IP address.
Related article: |

