Windows has 2 default gateways set and the first is which is causing network failures

You may have installed a new Windows 2008 server or Windows 7 workstation with a static IP address but networing outside your localnet fails. After you investigate you find by running “ipconfig” that there is 2 default routes listed. You see first and then you see your real default router IP address below the address.

This is preventing you from accessing the Internet as it believes the first route to the internet is your local IP address and it goes nowhere. You need to get the first route out but if you use “route delete” on the next reboot it will right back and you will be left without Internet access so what do you do?

You need to edit the registery and remove the entry listed in the default route key. To do this go to:

HKLM\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\Interfaces\your interface #\DefaultGateway

You will most likely find if you edit this key 2 IP addresses listed and the one you want being listed as the second IP in the list. Just remove all IP addresses but the real gateway address.

Close and reboot then try to ping out and it should now work.



7 Responses to “Howto : Remove Windows Server 2008 / Windows 7 multiple default gateways with the first being”

  1. Ryan says:

    Thanks for posting this. It was very helpful and saved me a lot of time troubleshooting this morning.

  2. David says:

    This fixed my issue! Thanks!

  3. Claudio says:

    Thank you!!

  4. Lelala says:

    THANKS for posting this.
    It took me 1h to find out whats wrong, another 10 min. to change all settings…


  5. Lelala says:

    Oh yes, by the way: the final reboot was not necessary, at least in my case. You can findout if all settings are correct, just by giving again “ipconfig /all” into the command line.
    –> even without a reboot a the values are shown correctly.

    again: MANY thanks!! you saved my weekend, pal!!!

  6. I see you don’t monetize your blog, don’t
    waste your traffic, you can earn additional bucks every month because you’ve got high quality content.
    If you want to know how to make extra $$$, search for: Mrdalekjd methods
    for $$$

  7. Brent says:

    Over 7 years after you posted this and this is the only article I could find for my issue. Thanks!

Leave a Reply