How I tested how fast my website is over the ocean

I checked my self hosted blog from about 40 cities with check-host.net, to see how fast it opens in America and Asia.

This blog runs on a small server in my homelab. From my home it opens very fast, and from other places in Europe it also looked fine. But I never knew how it works for a person in America or in Asia. I do not know anybody there who could open it and tell me. So this week I tried to measure it.

The tool

I used check-host.net. It is free, and it has test nodes in many countries. It also has a simple API, so I did not need to click in the browser. One request starts a check from all nodes:

curl -s -H 'Accept: application/json' 'https://check-host.net/check-http?host=https://dbashkatov.com/&max_nodes=40'

The answer has a request_id. After about a minute, https://check-host.net/check-result/<request_id> gives the result of every node: OK or not, and the time.

There is also check-tcp, which only opens a connection and sends nothing. I ran both, three rounds each, one after another. A small script put everything into one list per city.

For comparison I measured the server from my own network. The first byte comes in about 20 ms, and the page is only 37 KB with gzip. So the server itself is fast, and everything else is the network.

The results

This is the time for the whole page request, about the middle value of three rounds:

  • Frankfurt: 0.15 s
  • London: 0.21 s
  • New York: 0.52 s
  • Atlanta: 0.53 s
  • Vancouver: 0.68 s
  • Los Angeles: 0.70 s
  • Singapore: 0.95 s
  • Sao Paulo: 1.03 s
  • Tokyo: 1.09 s
  • Hong Kong: 1.7 to 2.3 s

So over the ocean the page takes about half a second to America and about one second to Asia. The server needs only 20 ms of this.

The TCP check shows it better. Only to open a connection takes 0.05 s from London, 0.15 s from New York and 0.28 s from Tokyo. A page needs a few such trips: the connection, the TLS handshake and the request itself. So from Tokyo the time is spent mostly on waiting for packets to travel, and a faster server would not change much.

What I think about it

I think it is acceptable for a small blog. A CDN would make it faster for far countries, but I do not want to depend on one more service now.

It was also interesting to see that the numbers are quite stable. Most cities gave almost the same time in all three rounds, for example Tokyo 1.13, 1.09 and 1.09 s. But sometimes one round was much slower, London once took 2.33 s instead of 0.21 s. So I think it is better to run a few rounds and not to trust only one.