Hy there,

I was wondering if it is possible to have two different networks connected on one router who which have the same ip, and are differentiated by a subnet mask?

For example:

Are they considered different because their network prefix is different?

Does that mean that with the ip address we can actually address. -> 2 computers - 2 (for broadcast and network name)

+ -> 4 computers - 2

+ -> 8 computers - 2



Does it mean that we can uniquely define adresses for, what ever the number turns out to be, computers?

  • Great question, I think a lot people make this assumption and its good to have it answered here authoritatively. – SpacemanSpiff Sep 24 '12 at 19:29

No, it does not. The subnet mask is used exclusively for routing decisions (the routing algorithm needs a hint what hosts are local and what needs to be sent to a gateway), the addresses have to be unique in any case.

See also: http://en.wikipedia.org/wiki/IP_forwarding_algorithm

But you can set the netmask arbitrarily to match your requirements on subnet size, of course.

There are also techniques (mainly NAT) which would allow two networks with overlapping IP address spaces to communicate by remapping the overlapping address spaces to unique ones. In your example, with two separate networks A and B both including subnets of, the remote subnet could be presented as a different, not yet used subnet - e.g. The router would perform the necessary address translation operations forth and back to re-establish address uniqueness as visible by each of the networks A and B.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.