1

If I plug my router into my modem, I have one public IP address (as reported by https://www.whatismyip.com and the like). When I plug my computer directly into the modem, my public IP address changes. If I go back to using the router, my public IP address returns to its original value.

Why are my public IP addresses specific to the devices that plug into the modem, rather than staying with cable modem itself?

4
  • 1
    When a computer is connected directly to the modem, do you see the same public address in the computer's own network connection info? For example in ipconfig or ncpa.cpl or the Windows' settings app? Commented Feb 20, 2019 at 19:49
  • @MaxB: Then please check them. Commented Feb 20, 2019 at 20:47
  • @MaxB: So the computers still get a "private" address, even without a router? Then I think David's answer does not apply. Can you log in to the modem itself, and check what WAN address that is showing (if any at all)? Is it maybe showing a "private" WAN address, or something from the 100.64.0.0/10 range? Commented Feb 21, 2019 at 4:58
  • @grawity Sorry, I misunderstood the Q originally. The device connected to the modem gets the "external IP" as far as I can tell.
    – MWB
    Commented Feb 22, 2019 at 0:04

2 Answers 2

5

Your modem is probably literally just a modem as far as IP is concerned. It doesn't have a public IP address assigned to it. When a device connects to your Internet connection, it has to establish a connection and the modem just translates signals. Your ISP sees the hardware address of the device that's connected to your modem and sees if it has a public IP address already associated with that hardware address.

0

IP addresses are almost always assigned dynamically using DHCP. DHCP uses your MAC address along with possibly some other things like the hostname and UID (unique client identifier). Your router that you normally use to share your IP address with all of your computers has its own MAC address, just like your computer does when you connect it directly.

The DHCP server remembers all the MAC addresses that were recently used to obtain an IP address and it tries to hand out the same IP address each time the same MAC address is plugged in, if the IP address hasn't been reused and assigned to a different host.

A regular DOCSIS cable modem will allow you to have up to 7 devices connected directly to it using an Ethernet hub or switch. Whether or not this will work depends on if your ISP allows it. Some will allow multiple devices to be plugged directly and obtain separate public IP addresses, at least for a while. Others may want to charge extra money to have an additional host connected directly. It seems like your ISP allows multiple devices to connect directly at once, at least for a while.

If your ISP does not allow multiple hosts to be connected directly at the same time, connecting a new host with a new MAC address may cause the account sign up captive browser portal to show up. Then you have to enter your account information to allow the new router or computer to connect.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .