The first step begins before you even press the button: we look up your IP address in a GeoIP database to determine your approximate location. This tells us where to center the map—but more importantly, it also tells us which servers are nearby. After loading the list of 1000+ servers and the appropriate map tiles, we can display the map of hosts on the front page.
Once you press Begin Test, we take your location and determine up to five nearby servers (using spherical geometry). We then ping those nearby servers, and choose the server with the lowest result, meaning it took the shortest time for a response. This is the server that's "closest" on the network, and usually provides the most accurate results. We can then begin the full test process: measuring your ping, download speed, and upload speed. (For more information, you can read our article on the full testing methodology used on Speedtest.net.)
If you're using one of our mobile apps, this process all happens in the background before you press Begin Test. In addition, we can use the Android or iOS location services to determine a more accurate location fix.