Windows, IPv6 and DHCP

Windows clients and servers will use DHCP for IPv6 addresses even when you set static IPv6 address. Not only that, but Windows client will prefer DHCP IPv6 address over static one.

On below picture we can see that ipconfig returns two IP addresses. First one is set as static IP address, second is obtained through DHCP.


We can change this behavior, by disabling DHCP. First, we run command:


and locate interface ID. In my case interface ID is 4. Next, we run the command that disabled DHCP for that interface

Set-NetIPInterface -InterfaceIndex 4 -DHCP Disabled

After the change, we can see that DHCP based IPv6 address is not present any more and internet sites can see correct (static) IPv6 source address.

Thank you @Luka Manojlovič for keep reminding me what I need to do to fix this. I finally got down to writing it down.

Comments are closed