How to Get a Public IP Address (2026 Step-by-Step Guide)

Want to host a game server, run a website from home, or access your device remotely? You’ll need a public IP. Here’s exactly how to get one — the easy way and the technical way.

What Is a Public IP Address?

A public IP address is a unique address assigned to your network by your Internet Service Provider (ISP) that’s visible to the entire internet. It’s what allows other devices, servers, and websites out in the world to find and connect to you — unlike a private IP, which only works inside your home or office network.

  • Globally unique — no two devices on the internet share the same public IP at the same time
  • Assigned by your ISP — either to your router directly or shared across multiple customers
  • Required for inbound connections — hosting a server, remote access, or port forwarding all need one
  • Can be static or dynamic — fixed permanently, or changed periodically by your ISP

Public IP vs Private IP

FactorPublic IPPrivate IP
VisibilityVisible across the internetVisible only within local network
Assigned byISPYour router
Example103.22.45.10192.168.1.5
Used forHosting, remote access, gaming serversCommunication between devices at home/office

How to Check If You Already Have One

Before trying to “get” a public IP, check whether you already have one:

Step 1 — Search “what is my IP” on Google, or visit a site like whatismyip.com — note the address shown.

Step 2 — Log into your router’s admin panel and check the WAN/Internet IP address.

Step 3 — Compare the two. If they match, you already have a public IP directly on your router. If they don’t match (or your router shows an address starting with 10.x, 100.64.x, or 172.16–31.x), you’re likely behind CGNAT — a shared IP system many ISPs use.

How to Get a Public IP From Your ISP (Method 1)

If you’re behind CGNAT or a shared IP, the most direct route is asking your Internet Service Provider directly.

Step 1 — Contact your ISP’s support and ask for a “static public IP address” or “dedicated IP” add-on.

Step 2 — Some ISPs offer this for free on business plans; others charge a small monthly fee for residential connections.

Step 3 — Once assigned, restart your router and re-check your IP using the same method as above to confirm it’s now public.

Method 2: Use a VPN With a Dedicated IP

If your ISP won’t provide a public IP, some VPN providers offer a dedicated/static IP add-on. This routes your traffic through a fixed public IP owned by the VPN provider — useful for remote access or bypassing CGNAT, though it’s not a substitute for a true ISP-assigned public IP for hosting purposes.

Method 3: Use a VPS or Dedicated Server

If you’re trying to host a website, game server, or application — not just access your home network remotely — the simplest and most reliable path is renting a VPS or dedicated server, which always comes with a public IP included by default.

  • No CGNAT issues — every VPS ships with its own dedicated public IP
  • No dependency on home internet uptime — the server runs in a professional data center
  • Better bandwidth and reliability — built for 24/7 hosting, unlike a home connection
  • Root access — full control to configure firewalls, ports, and services as needed

👉 Skip the ISP hassle entirely — every HostGraber VPS plan comes with a dedicated public IP by default.

Static vs Dynamic Public IP

Dynamic public IP — changes periodically (e.g., when your router restarts or your ISP rotates addresses). Fine for casual browsing, but unreliable for hosting anything long-term.

Static public IP — stays fixed permanently. Essential if you’re running a server, setting up remote access, or need a consistent address for DNS records to point to.

If you can’t get a static IP from your ISP, a Dynamic DNS (DDNS) service can help — it automatically updates a domain name to always point to your current dynamic IP.

Security Tips When Using a Public IP

  • Enable a firewall — block all ports except the ones you actually need open
  • Change default passwords — on your router and any exposed services
  • Keep software updated — outdated services are the most common attack entry point
  • Use SSH keys instead of passwords — for any server you access remotely
  • Monitor access logs — watch for repeated failed login attempts from unknown addresses

Final Thoughts

Getting a public IP depends on what you’re actually trying to do. For occasional remote access, an ISP add-on or VPN dedicated IP might be enough. But if you’re hosting anything meant to stay online reliably — a website, game server, or application — a VPS or dedicated server with a built-in public IP is almost always the simpler, more stable choice.

FAQs

Q1. How do I get a public IP address for free?

Some ISPs assign a public IP by default with no extra charge — check your router’s WAN IP against “what is my IP” to see if you already have one before paying for an add-on.

Q2. Why doesn’t my router show a public IP?

You’re likely behind CGNAT (Carrier-Grade NAT), a system many ISPs use to share one public IP across multiple customers — you’ll need to request a dedicated one directly.

Q3. Is a public IP safe to use?

Yes, as long as you configure a firewall and secure any exposed services — a public IP itself isn’t a security risk, but leaving open ports unprotected is.

Q4. Do I need a public IP to host a website?

Yes — a public IP is required for other devices on the internet to reach your server. Most people simplify this by using a VPS, which comes with one built-in.

Q5. What’s the difference between a public IP and a static IP?

A public IP just means it’s visible on the internet — it can still change over time (dynamic). A static IP is a public IP that stays fixed permanently.

Need a public IP without the ISP hassle?

Get a VPS with a dedicated public IP included

NVMe SSD storage, full root access, and 24/7 support — starting at ₹229/month.


View VPS Plans →