What Is a Static IP Address? Static vs Dynamic IP and How to Set One
Short answer
A static IP address is an IP address that doesn’t change: it is set by hand or always assigned to the same device. A dynamic IP is assigned automatically by DHCP and can change, and most home internet plans come with a dynamic public IP. A static public IP has to come from your internet provider, but you can give a device a fixed local IP yourself with a DHCP reservation on your router.
On this page
A static IP address stays the same until someone changes it, while a dynamic one is assigned automatically and can change. Both exist at two levels: the public IP your internet provider gives your connection, and the local IPs your router gives your devices. This page compares them, shows how to check which one you have, and walks through getting or setting a static IP on your router, computer and phone.
What is a static IP address?
A static IP address doesn’t change, because it was entered by hand or the network always assigns it to the same device. That’s the whole meaning of “static IP”: it says nothing about whether the address is public or private, and the two kinds are set up in different places:
| Static public IP | Static local IP | |
|---|---|---|
| What it is | Your connection’s address on the internet | One device’s address on your home network |
| Example | 203.0.113.25 | 192.168.1.50 |
| Assigned by | Your internet provider (ISP) | Your router, or you on the device |
| How to get it | Order it from your ISP, often with a business plan | Set it up yourself, at no cost |
| Typical uses | Servers, remote access, IP allowlists | Printers, NAS drives, cameras, game consoles |
No router or computer setting creates a static public IP; only your ISP can. Local IP addresses explains the private ranges, such as 192.168.x.x.
What is a dynamic IP address?
A dynamic IP address is assigned automatically and can change. On your network, the router does this with DHCP (Dynamic Host Configuration Protocol): it lends each device an address for a set time, called a lease. Under RFC 2131, the DHCP standard, a device tries to renew its lease halfway through, so it keeps its address while it stays connected. After a long time offline, it can get a different one.
Your ISP hands out public IPs in a similar way. A dynamic public IP often stays the same for weeks or months, then changes after an outage, a new modem or maintenance on the ISP’s side.
Static IP vs DHCP isn’t a strict either-or. RFC 2131 also defines manual allocation, where an administrator picks the address and DHCP delivers it. Routers call this a DHCP reservation.
Static vs dynamic IP: what’s the difference?
| Static IP | Dynamic IP | |
|---|---|---|
| How it’s assigned | Entered by hand, or reserved for one device | Automatically, by DHCP |
| When it changes | Only when you or your ISP change it | Can change after a lease expires, an outage or a reconnect |
| Cost of a public IP | Often extra, or only with business plans | Included in your plan |
| Servers, remote access, allowlists | Same address every time | Needs dynamic DNS, or list updates after each change |
| Security | Exposed services stay at one known address | A changing address is no real protection |
| Privacy | The same address for months or years | Changes now and then, but still shows your ISP and area |
| Speed | No difference | No difference |
| Typical use | Servers, offices, printers, NAS drives | Home internet, phones, laptops |
A public IP, static or dynamic, reveals your ISP and approximate area, not your name or street address; what an IP address tells you has the details.
When do you need a static IP?
You need a static public IP when others must reach or recognize your connection at the same address:
- Servers: a website, mail server or game server on your own connection.
- Remote access and VPN servers: people connecting to a VPN server, remote desktop or a camera system without a cloud service.
- IP allowlists: company firewalls, cloud databases, admin panels and some APIs accept only listed addresses. Before you add an address to such a list, our IP lookup API shows which provider and network it belongs to.
- VoIP and office links: some business phone lines (SIP trunks) and office-to-office VPNs are set up by IP address.
You don’t need one to browse, stream, make video calls, play online or connect to your employer’s VPN, because your device starts those connections. Cameras and doorbells that work through the maker’s app don’t need one either.
For gaming, a static IP doesn’t lower ping. Your NAT type (Open, Moderate or Strict on Xbox; Type 1 to 3 on PlayStation) matters more, and it improves with UPnP or with port forwarding to a console that has a fixed local IP.
Warning
Anything you expose on a static IP stays at one address, where automated scanners find it too. Open only the ports a service needs, and keep your router and servers updated.
Dynamic DNS: an alternative to a static IP
Dynamic DNS (DDNS) gives your connection a hostname, such as home.example.net, that follows your public IP: your router or a small app at home reports each change, and the service updates the record. Many routers have DDNS built in, and some router makers include a free hostname. DDNS covers most home needs, like reaching a NAS or camera system by name. It can’t replace a static IP for allowlists, can lag a few minutes behind a change, and doesn’t work behind carrier-grade NAT (see the note below).
How to tell if your IP is static or dynamic
Check your public IP
The box shows the public IP your connection uses right now. Turn off any VPN or iCloud Private Relay first.
Your public IP address
216.73.216.128
- Location
- Columbus, Ohio, United States
- Provider
- Anthropic, PBC (AS16509)
- Time zone
- America/New_York (UTC−4)
- Coordinates
- 39.96, -83.00
This is the address websites see, and the location is an estimate that can be off by a city or more. Your device's local IP (often 192.168.x.x) is a different one and only works inside your network.
- Write down the IP address from the box.
- Restart your modem and router.
- Reload this page and compare.
A changed address is dynamic. An unchanged one can still be dynamic, since many ISPs hand back the same address for weeks, so compare again after a few days. Your router’s Internet or WAN status page shows the connection type (how to find your router’s IP address explains how to open it): Static IP means a fixed address; DHCP, Dynamic IP or PPPoE usually means dynamic, though some ISPs deliver static IPs that way. Your plan has the final say. With an IPv6 address in the box, compare only the first four groups, the network prefix.
Note
If the router’s WAN IPv4 address is between 100.64.0.0 and 100.127.255.255 (100.64.0.0/10), your ISP uses carrier-grade NAT (CGNAT): you share a public IPv4 address with other customers, and port forwarding and dynamic DNS don’t work over IPv4. Ask your ISP for a public IPv4 address. A private WAN address such as 192.168.x.x usually means another router or ISP gateway sits in front of yours.
Check a device’s local IP
A device’s network settings show whether it gets its local IP automatically:
- Windows: run
ipconfig /allin Command Prompt. DHCP Enabled reads Yes for an automatic address and No for a manual one. - Mac: Configure IPv4 in the TCP/IP settings reads Using DHCP or Manually.
- iPhone and iPad: Configure IP reads Automatic or Manual.
- Android: IP settings reads DHCP or Static.
- Linux: in the output of
ip addr, addresses from DHCP are markeddynamic.
An automatic address can still be fixed by a reservation, which only the router’s settings show.
How to get a static IP address from your ISP
Many US providers offer static IPs only with business plans; some sell one as an add-on for home service. Mobile, 5G home internet and satellite connections often use CGNAT and may offer no static IP at all. Before you order, ask:
- The monthly cost, any setup fee, and whether you need a business plan or contract.
- How many addresses you get. In a block of 8, usually 5 are usable; the network, gateway and broadcast addresses are reserved.
- Whether your IPv6 prefix is static too, and whether you can set reverse DNS (PTR) for a mail server.
- Whether you can use your own router or must keep the ISP’s gateway.
After activation, the ISP sets up its gateway, or you enter the IP address, subnet mask, gateway and DNS servers in your router’s WAN settings with the connection type Static IP. Then check the box above.
How to set a static local IP address
DHCP reservation vs static IP: which to use
| DHCP reservation (on the router) | Manual static IP (on the device) | |
|---|---|---|
| Where you set it | Router admin page or app | The device’s network settings |
| Device setting | Stays on automatic (DHCP) | Manual |
| IP conflicts | The router never gives the address to another device | Possible if the address is inside the router’s DHCP pool |
| Devices without a network menu | Works for printers, cameras, smart plugs | Not possible |
| Best for | Almost every device at home | Servers and network gear, or when you can’t change the router |
Use a reservation when you can; Raspberry Pi’s documentation recommends it for the Pi, too.
Reserve an IP address on your router
Look for DHCP Reservation, Address Reservation, Reserved IP, Static Lease or Manually Assigned IP under LAN, DHCP Server or the list of connected devices; menus vary by brand.
- Open your router’s admin page or app and sign in.
- Open the list of connected devices or the DHCP settings.
- Select the device, or add a reservation with its MAC address.
- Choose the IP address it should keep. Many routers suggest its current one.
- Save or apply the change.
- Reconnect or restart the device so it picks up the address.
Phones and tablets use a private (randomized) MAC address on Wi-Fi, and a reservation holds only while that address stays the same. On an iPhone or iPad (iOS 18 or later), set Private Wi-Fi Address to Fixed for your home network; on Android, set Privacy to Use device MAC if a reservation doesn’t hold.
Values for a manual static IP
| Field | Example | Where to get it |
|---|---|---|
| IP address | 192.168.1.50 | A free address outside the router’s DHCP pool |
| Subnet mask | 255.255.255.0 (prefix length 24) | Same as your other devices |
| Gateway (router) | 192.168.1.1 | Your router’s local IP |
| DNS server | 192.168.1.1 | Usually your router, or DNS servers you prefer |
Read your network’s values from a device that gets its address automatically.
Tip
Your router’s LAN or DHCP settings show the DHCP pool, the range it hands out. If that’s 192.168.1.100 to 192.168.1.199, an address such as 192.168.1.50 can’t collide with one the router hands out.
Windows 11 and Windows 10
On Windows 11:
- Press Windows key + I to open Settings.
- Select Network & internet.
- Select Wi-Fi, or Ethernet for a cable connection.
- For Wi-Fi, select (network name) properties.
- Next to IP assignment, select Edit.
- Change Automatic (DHCP) to Manual.
- Turn on IPv4.
- Enter the IP address, Subnet mask and Gateway.
- Enter your DNS server in Preferred DNS.
- Select Save.
On Windows 10, open Settings > Network & Internet > Wi-Fi > Manage known networks, select your network, then Properties; it asks for a Subnet prefix length (24) instead of a subnet mask. To undo the change, switch back to Automatic (DHCP). Microsoft covers both versions under “Change TCP/IP settings” in Essential network settings and tasks in Windows, and finding your IP address on Windows shows your current gateway and DNS server.
Mac
- Choose Apple menu > System Settings.
- Click Network in the sidebar.
- Click Wi-Fi or your Ethernet service.
- Click Details next to the network you’re connected to.
- Click TCP/IP.
- Set Configure IPv4 to Manually.
- Enter the IP address, Subnet mask and Router.
- Click DNS.
- Click the Add button (+) below the list of DNS servers and type your DNS server.
- Click OK.
The steps match macOS 27 Golden Gate back to macOS Ventura 13; Apple describes them in Use DHCP or a manual IP address on Mac. Finding your IP address on a Mac shows your current values.
iPhone and iPad
- Open Settings.
- Tap Wi-Fi.
- Tap the More Info button (i) next to your network.
- Tap Configure IP.
- Tap Manual.
- Enter the IP Address, Subnet Mask and Router.
- Tap Save.
- Tap Configure DNS, then Manual.
- Tap Add Server and type your DNS server.
- Tap Save.
The steps match iOS 27 and iPadOS 27, and the setting applies only to that Wi-Fi network.
Android
On a Google Pixel or another phone with Android 17:
- Open Settings > Network & internet > Internet.
- Tap the settings (gear) icon next to your Wi-Fi network.
- Tap the edit (pencil) icon at the top.
- Tap Advanced options.
- Under IP settings, choose Static.
- Enter the IP address, Gateway, Network prefix length (24 for 255.255.255.0) and DNS 1.
- Tap Save.
On a Samsung Galaxy, open Settings > Connections > Wi-Fi, tap the gear icon next to your network, then tap View more to reach IP settings.
Ubuntu static IP with Netplan
On Ubuntu Server, find your interface name with ip a (for example, enp3s0), then create /etc/netplan/99_config.yaml:
network:
version: 2
ethernets:
enp3s0:
dhcp4: false
addresses:
- 192.168.1.50/24
routes:
- to: default
via: 192.168.1.1
nameservers:
addresses: [192.168.1.1]Netplan applies its files in alphabetical order, so dhcp4: false here overrides DHCP from the default file. Make the file readable by root only, then test it:
sudo chmod 600 /etc/netplan/99_config.yaml
sudo netplan trynetplan try undoes the change after 120 seconds unless you confirm it, so a typo can’t lock you out of a remote server; sudo netplan apply skips that safety net. The Ubuntu Server networking guide has more examples.
Raspberry Pi static IP (nmcli)
Raspberry Pi OS (Bookworm and later), Ubuntu Desktop and Fedora use NetworkManager. List your connections, then set the address, replacing “Wired connection 1” with your connection’s name:
nmcli connection show
sudo nmcli connection modify "Wired connection 1" ipv4.method manual ipv4.addresses 192.168.1.50/24 ipv4.gateway 192.168.1.1 ipv4.dns 192.168.1.1
sudo nmcli connection up "Wired connection 1"Over SSH, the session drops; reconnect at the new address. Raspberry Pi OS Bullseye and older use /etc/dhcpcd.conf instead. Finding your IP address on Linux shows how to check the result.
Static IP problems and how to fix them
| Problem | Likely cause | Fix |
|---|---|---|
| Two devices have the same IP | A manual address inside the DHCP pool | Switch one device back to automatic, or pick an address outside the pool |
| Local network works, internet doesn’t | Wrong or missing gateway or DNS server | Enter your router’s IP as the gateway, add a working DNS server, and check the subnet mask |
| Device unreachable after a router change | The new router uses another range, such as 192.168.0.x | Update manual addresses; recreate reservations unless you restored a settings backup |
| IPv6 addresses keep changing | Static IPv4 settings don’t cover IPv6; devices rotate temporary IPv6 addresses, and the ISP’s prefix can change | Reach home devices by their reserved IPv4 address; ask your ISP whether your IPv6 prefix is static |
Frequently asked questions
How would I know if my IP is static?
Note your public IP address, restart your modem and router, and check again: if the address changed, it’s dynamic. If it stayed the same, it can still be dynamic, because many internet providers hand back the same address for weeks, so check your plan or ask your provider. For a device’s local IP, Windows shows DHCP Enabled: No in the output of ipconfig /all when the address was set by hand.
How do I create a static IP address?
For a device on your home network, create a DHCP reservation in your router so the device always gets the same local IP, or enter a manual IP address, subnet mask, gateway and DNS server in the device’s network settings. You can’t create a static public IP yourself. Your internet provider has to assign it, usually with a business plan or as a paid add-on.
Do I need a static IP for VPN?
No, not to use a VPN service or connect to your employer’s VPN, because your device starts those connections. You need a static public IP, or dynamic DNS, only to run a VPN server that others connect to, and your connection must have its own public IPv4 address rather than carrier-grade NAT. A dedicated IP sold by some VPN services is a fixed address on the VPN’s server, not on your connection.
Is static IP better for gaming?
Not for speed: a static IP doesn’t lower your ping or raise your bandwidth. Online games care about your NAT type, which improves with UPnP or port forwarding on your router, and a fixed local IP for your console keeps port forwarding rules working. If your internet provider uses carrier-grade NAT, ask it for a public IPv4 address.
Is a static IP faster or safer than a dynamic IP?
Neither is faster: speed depends on your plan and network, not on whether the address changes. Safety depends on what you expose. A static IP keeps any open service at the same address, so keep your router and servers updated and open only the ports you need. A dynamic IP isn’t anonymous either, since it can stay the same for weeks and still points to your provider and area.
Should I use a DHCP reservation or a static IP?
For home devices, a DHCP reservation is usually the better choice: you set it once in the router, the device keeps its automatic settings, and the router never gives that address to another device. A manual static IP on the device suits servers and network equipment, or networks where you can’t change the router. If you set one manually, pick an address outside the router’s DHCP pool.