There are times I need to get the list of the IP addresses – usually just IPv4 addresses since use of IPv6 addresses is still not widespread yet – on a Windows server. There are various ways to do this. One of the simplest is to use ipconfig. This is a command-line utility that has been a part of Windows since the early days. Without any options, it returns the IP addresses and subnet masks for every network adapter.

Note the link-local IPv6 address includes a scope id (% followed by the network adapter id). Because link-local addresses are not guaranteed to be globally unique, the scope id is used to identify the network adapter used for the address. This is important on systems with multiple network adapters.


