Reduce game network latency in Windows 7 or Vista


After installing Windows 7 I noticed a slight increase in network latency in several online games. It wasn’t a big deal – I’m talking 200-300ms, but this is on a connection that was reliably < 100ms in the past. Beyond the obvious settings in Windows or on your router, here’s a list of tweaks that may help quite a bit. It involves disabling Nagle’s algorithm, also commonly known as TCP no delay, which is basically an optimization of network traffic that tries to reduce overall packet volume but can cause extra latency in the connection. This should work on Windows 7 or Vista, though the same principle can probably applied to other operating systems as well.

  1. From a command prompt (usually in All Programs -> Accessories -> Command Prompt) run “regedit”
  2. Browse to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\Tcpip\Parameters\Interfaces
  3. Browse the items under interfaces until you find one that has an IPAddress entry matching the network interface you want to affect (typically LAN IP addresses start with 192.168 or 10.0); note that if your IP address is automatically assigned by a DHCP server you may need to look for a matching DhcpIPAddress instead of IPAddress
  4. Right-click on the interface and select New > DWORD (32-bit) Value, name it “TcpAckFrequency”
  5. Right-click the new TcpAckFrequency value and select Modify, enter “1″ (Hexadecimal radio button should be selected)
  6. Right-click on the interface and select New > DWORD (32-bit) Value, name it “TCPNoDelay” (note that TCP is all uppercase this time – that’s intentional)
  7. Right-click the new TCPNoDelay value and select Modify, enter “1″ (Hexadecimal radio button should be selected)
  8. Verify that both TcpAckFrequency and TCPNoDelay now show up in the adapter’s property list with types REG_DWORD and values 0×00000001
  9. Exit regedit and reboot (reboot is necessary for the changes to take effect!)
  10. Play a game and enjoy your new low ping

This decreased my ping in most games from 200-300ms to 50-60ms, which matches the latency I would see via a tracert to the game’s server.

If you like this entry please share it using the links below!
  • Digg
  • Reddit
  • StumbleUpon
  • del.icio.us
  • Technorati
  • Google Bookmarks
  • LinkedIn
  • Facebook
  • Yahoo! Buzz
  • Twitter

, , , , , , ,

  1. #1 by Alan on November 11, 2009 - 1:11 pm

    I will try this… but if I may ask, where might I find a description of the “obvious settings in Windows or on your router”?

    Thanks!

  2. #2 by Ken on November 13, 2009 - 10:24 am

    Thanks a lot, my ping change from 23x to 5x …

    Thanks again

  3. #3 by Unpleasant on November 18, 2009 - 4:33 pm

    I followed this guide and went from 190-240ms to 45-55ms, thanks for sharing :)

  4. #4 by Dhaval on December 1, 2009 - 12:00 pm

    Thaks
    but it din work for me
    i m using windows7(x64)
    i tried both d-word n q-word but din work
    helpppppp plz

  5. #5 by Thomas on December 3, 2009 - 12:39 pm

    it works for me with windows 7 ultimate 64 bit … make sure you make a 32-bit DWORD .
    good luck

  6. #6 by beats on December 4, 2009 - 10:32 am

    # Verify that both TcpAckFrequency and TCPNoDelay now show up in the adapter’s property list with types REG_DWORD and values 0×00000001

    How do you check this?

  7. #7 by Trudy on December 6, 2009 - 8:13 pm

    ty ty ty …… I just spent a fortune getting my computer fixed and since they had to reinstall the OS I had them put windows 7 in (x64 by the way) and was getting latency 300-1000. You instructions were easy to follow and now I’m at 60-80 latency. I really appreciate your post!!!

  8. #8 by Dustin on December 7, 2009 - 4:01 pm

    Trudy :

    ty ty ty …… I just spent a fortune getting my computer fixed and since they had to reinstall the OS I had them put windows 7 in (x64 by the way) and was getting latency 300-1000. You instructions were easy to follow and now I’m at 60-80 latency. I really appreciate your post!!!

    Glad to help!

  9. #9 by Crusherix on December 7, 2009 - 5:20 pm

    Hey there, just a quick question, is it in the same map where all the ips are that i should create those new dwords? or is it in the “Interfaces” map that i should create them in?

    A simple screenshot would help more than a thousand words here =)

  10. #10 by dercor on December 10, 2009 - 7:22 am

    Thomas :
    it works for me with windows 7 ultimate 64 bit … make sure you make a 32-bit DWORD .
    good luck

    There is no place that i can choose DWORD as 32 or 64 bit, it just creates one. How can i choose as 32 ?

    Thanks in advance

  11. #11 by Czenda on December 12, 2009 - 10:42 am

    Every fix we tried just helped a bit but nothing solved it.

    It’s happening on a single-core computer and any cpu-hungry process causes to increase ping to that machine from LAN, like playing a HD video. Ping from other LAN computer goes to 30-150.

    Any idea why is this happening?

  12. #12 by muhehe on December 17, 2009 - 11:09 am

    how this TCP tweak can affect UDP packets which games use for transfering ingame data?

  13. #13 by FelikZ on December 20, 2009 - 12:44 pm

    Ok. I guess that I find whats the problem.
    I have ping 35-50 over XP and 35-200 over Win7 when I play CS 1.6
    When I set lower priority to process, the ping become normal.
    Also I test “fps_modem 35″ command, which is set game FPS to 35 and have the same result – normal ping.
    CPU Load conflicts with network sevice or something like that.
    (Sorry for bad English)

  14. #14 by Johnny on December 21, 2009 - 7:41 pm

    I just this week did a clean install of Windows 7 Ultimate. I was previously using WinXP. It seems Win7 does something odd to online games.

    However this fix worked like a charm, Thankyou.

  15. #15 by exezic on December 26, 2009 - 9:47 am

    Hey Czenda

    What is causing the lag is the “Multimedia Class Scheduller” service. all you need to do is:
    1. Disable the Multimedia Class Scheduler service.
    2. Sound is dependent on this service so you will then need to run regedit, then find HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Audiosrv\DependOnService
    3. Double click on it and remove MMCSS from the list.
    4. Reboot your computer
    5. ???
    6. PROFIT!

  16. #16 by Anthony on December 26, 2009 - 2:18 pm

    I’m a 19 year old gamer who just got a nice HP laptop built for gaming. The only problem I’m having is the latency. Now, even though I do a lot of things on the computer, certain concepts are beyond me. I’m stuck on step three, where I have to find an “IPAddress entry” I have the folders pulled up now, and they are called {846ee (string of numbers and letters)} I can’t seem to see the IP Address D: Can anyone email me at ryu.almosthuman@gmail.com and lead someone who knows nothing about this through?

  17. #17 by Suspicious on December 29, 2009 - 2:28 am

    So, I’ve been reading that there is a free TCP Optimizer program that does something like what you are describing.. I also read that TCP Optimizer is a trojan. Now with your this process of editing registry, does this open up a a computer to attack from viruses??

    Also, do you know anything about TCP Optimizer trojan?

  18. #18 by Suspicious on December 29, 2009 - 2:28 am

    *Trojan Ace

  19. #19 by Sendaii on January 2, 2010 - 4:32 pm

    My ping is still a little on the high side compared to when I was running XP on my gaming rig, but it’s not the crippling lag that I had before using this fix. Thanks for posting it.

  20. #20 by Sendaii on January 2, 2010 - 4:33 pm

    Oh, and I’m running Windws 7 Ultimate x64.

  21. #21 by Dustin on January 4, 2010 - 10:58 am

    Suspicious :

    So, I’ve been reading that there is a free TCP Optimizer program that does something like what you are describing.. I also read that TCP Optimizer is a trojan. Now with your this process of editing registry, does this open up a a computer to attack from viruses??

    Also, do you know anything about TCP Optimizer trojan?

    There are tools out there that make this change for you and the TCP Optimizer sounds like one of them. The change itself is harmless – it won’t increase or decrease your exposure to viruses – but the programs implementing it certainly could be malicious. Since the program probably requires administrator access to update your registry it could be doing other things without your knowledge, so making the change yourself is probably the safest route if you’re comfortable doing it.

  22. #22 by Tomas on January 8, 2010 - 2:13 pm

    Ok i have a problem in number 3. I do have dynamic ip adress… but in folder {C0EDBEE7-29B9-4C32-97B6-D13154373B4F} i have so many IP files that i don’t know what to do.
    I could send a screen. If can’t tell me the answer here you can send it to my gmail. toma.pusnik@gmail.com.

  23. #23 by suren on January 23, 2010 - 8:16 am

    8) Verify that both TcpAckFrequency and TCPNoDelay now show up in the adapter’s property list with types REG_DWORD and values 0×00000001.

    How to verify both?Plz help me…

  24. #24 by MadGenius on January 27, 2010 - 3:02 pm

    Hi, I need serous help. Its a complete disaster. when I start to play the game (DMC4) it lags about 1 picture per 4-15s. when I did the “Reduce game network latency in Windows 7 or Vista”, lag dissappeard, but it didn’t get any better. Graffics gone completely mad, some kind of a “glitch”. For instance close camera to the face, nothing exept ears, eyeballs, tongue and teeth. candle lights- yellow squares??? srr for bad en. PLEASEE HHEEEELP!!!!!!!!!!

  25. #25 by jimmy on February 5, 2010 - 5:27 pm

    Suspicious,

    It’s not a trojan itself, but it works just like a trojan might, thus your antivirus thinks it’s a trojan. Nevertheless, before you do anything to the registry, it is always a good idea to create a Restore Point using System Restore in the event that something should go wrong.

  26. #26 by PleiadesDesign on February 5, 2010 - 9:46 pm

    Anyone still having trouble with this might be experiencing the same problems that we had on our systems. For some reason the BFE service (Base Filter Engine) is interfering with network traffic. We haven’t been able to figure out ‘exactly’ why this is yet. However, network latency goes away when the service is stopped. You might consider using this as a temporary work-around. If someone has a better fix for this, please let me know. I would love to have such information as well.

  27. #27 by Glass Teapots on February 5, 2010 - 10:01 pm

    Wow that really helped, thank you!

  28. #28 by arcanblade on February 8, 2010 - 4:10 pm

    i am xp where is lion from WoW

  29. #29 by Poomonkey on February 15, 2010 - 6:44 pm

    I went through all these steps, it lowered my latency numbers by about 75%…only issues I’m having right now is that I’m getting disconnected 5 or 6 times a day. Prior to doing this I would get disconnection issues maybe once a month, and only under network stress (uploading/downloading large documents). This is starting to cause issues with the people I run with seeing as I have an important roll in whats going on.
    I was wondering if there was a way to reverse this? I tried going back to my directory and getting into the same area that the guide said to follow, but the options once I get to the Interface part, everything has changed. I remember doing all the steps, and getting to this point I had 10+ clickable items, now when I go through I have 4, and none of them look anything like what I had before.
    I did this right around the time there was a patch in the game I play..I assumed this was the issue since no one else I spoke with was having any of these same issues. Is there anything I can do to decrease my disconnection issues?

  30. #30 by godsbane on February 18, 2010 - 5:51 pm

    MadGenius: You probobly need to A) update drivers or B) get a better video card.

  31. #31 by Delilah on February 28, 2010 - 6:30 am

    This worked for my computer like a charm (Windows 7 32 bit) but for my husbands computer (Windows 7 64 bit) it did nothing to fix the problem. Any ideas why that is? He’s still running anywhere from 600ms to 1000ms depending on the demand of the game.
    Any suggestions would be greatly appreciated.

  32. #32 by Cruzader on March 1, 2010 - 1:12 pm

    I’m using Win 7 Ultima (64bits) and it work perfectly.
    Went from +200/350 to +50/100.

  33. #33 by badur on March 13, 2010 - 8:41 am

    It works perfectly form me. I mostly play World of Warcraft. Latency before: 220. Latency after: 50

  34. #34 by Elayne on March 15, 2010 - 5:24 pm

    Addict on WoW and getting very frustrated about high latency when in big groups or performing dps roles. Also my fps drop to 4.
    Normal lat would be approx 110-140 and 62 fps.
    I’m running game on a one core machine, high end videocard. We tried basically everything short from throwing comp out of the window. Any suggestions would be helpful.

  35. #35 by Kyuu on March 17, 2010 - 1:45 pm

    I have done this to 200ms with and with out these settings, So there somthing with a miss, This is Win 7 64bit Ult

  36. #36 by adonis muscle on March 19, 2010 - 6:49 am

    Hey, i have problems still with my vista, i think i will retun to xp soon.

  37. #37 by Kanji on March 22, 2010 - 10:10 am

    How do you verify that the DWORD value is in the adapter list? I see alot of people sayin’ the same thing but no one replies >.>

  38. #38 by Dmitry on March 23, 2010 - 9:33 am

    Thanks man!

    Apreciate your efforts. Helped me a lot.

  39. #39 by Bwyan on March 24, 2010 - 1:31 am

    Is this guide usefull for Windows XP users as well?

  40. #40 by Floreum on March 24, 2010 - 5:19 pm

    http://ioj.com/v/n3vym
    I’m playing Guild Wars, and as it shows, this made it worse than improving it. The middle screenshot is when I misspelled “TcpAckFrequency” with a g instead of a q. Weird that it’s an improvement.
    I’ll have to see with other games like TF2 or L4D(2)

    I’m running Windows 7 professional 64-bit

  41. #41 by Henk on March 26, 2010 - 11:05 am

    Does this have any side effect when you’re not gaming?

  42. #42 by helphelphelp2323 on April 6, 2010 - 5:04 am

    i cant do step 2 it says the system conot find the path specificated

  43. #43 by helphelphelp2323 on April 6, 2010 - 5:14 am

    i done all the steps now

  44. #44 by Dustin on April 6, 2010 - 1:05 pm

    Henk :

    Does this have any side effect when you’re not gaming?

    It’s a change that will be active all the time, not just during games. However since games are the most likely place you’ll notice a 50-200ms latency difference it will probably have no visible effect during other activities.

  45. #45 by Jon on April 9, 2010 - 1:39 am

    According to microsoft, the TCPNoDelay command only works in (HKLM\SOFTWARE\Microsoft\MSMQ\Parameters). What does adding it to (HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\Tcpip\Parameters\Interfaces) do, if anything?

    http://technet.microsoft.com/en-us/library/cc783904%28WS.10%29.aspx

    Also, is adding TCPNoDelay “1″ even necessary if MSMQ isn’t installed? TcpAckFrequency definitely has an effect in Windows 7, but I’m not so sure about the other if MSMQ isn’t installed by default.

  46. #46 by Riez Co on April 16, 2010 - 12:27 am

    i follow ur guide and

    try the pingtest (http://www.pingtest.net/)

    and now …

    from Grade F to Grade C

    not bad =)

  47. #47 by Shaun on April 17, 2010 - 7:58 am

    Well for me TCPNoDelay and TcpAckFrequency helped a good bit but i still get laggy after playing for like 30 mins. I don’t play games you have to pay for tho i play CombatArms and since its a free MMOFPS im sure that has something to do with the lag but when i start its about 100 to 150 and i play more and more and it just goes up

  48. #48 by Shaun on April 17, 2010 - 8:07 am

    exezic :Hey Czenda
    What is causing the lag is the “Multimedia Class Scheduller” service. all you need to do is:1. Disable the Multimedia Class Scheduler service.2. Sound is dependent on this service so you will then need to run regedit, then find HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Audiosrv\DependOnService3. Double click on it and remove MMCSS from the list.4. Reboot your computer5. ???6. PROFIT!

    I see why that would work i read somewhere that the way Windows 7 was made that sending info was a low priority so that could make receving a high priority to download faster and the MMCSS sets how much of the CPU go towards low priority set items

  49. #49 by Marto on April 21, 2010 - 9:01 pm

    Hi thank you for the code! Me and my cousing are having latency problems on starcraft, and he always seems to be on high latency (full red bar) we are trying to do this solution but we get stuck on finding the IP (step 3.) as we do not know what IP we want to connect to. Te server is ICCUP but it has an IP that starts at 87.242 (according to who.is), and he cannot find any ip on regedit that starts with this ip (we are both trying to connect through DhcpIP)

    We do not have experience with this but we really want to play, what can we do?

    Thanks

  50. #50 by Brady on April 28, 2010 - 11:01 pm

    I dont have a lan, I use a router, and in step 3 under interfaces, i dont have a isp im usually like a 192.168.0.4 or w/e, I always have the, even when running laptop and xbox, so i know it doesnt just assign… Blkfiredrag@hotmail.com If anyone could help me, that would be great.

(will not be published)