How to use the ping command?

Ping is a tool with which test packets are sent via the network to a destination of your choice and where the response time is measured.

IN THIS ARTICLE:

What do you use the ping command for?

You can use Ping to:

  • Test whether your website or web server is available
  • Test the latency or delay of your internet connection
  • Check if you have “lag” (delay) or package loss

 

How do you use the ping command?

Follow these steps to use the Ping command on Windows:

  1. Use the search function to find your command prompt – type “cmd” in the search window and open the app.
  2. In the new window, type “ping” followed by a domain name or an IP address, for example:
      • Example: ping example.com
      • Example: ping 18.18.18.250
  3. Windows will stop your test after the 4th attempt.

Follow these steps to use the Ping command on Mac:

  1. Go to your programs and open “Terminal”.
  2. Type “ping” followed by a domain name or an IP address.
      • Example: ping example.com
      • Example: ping 18.18.18.250
  3. Let the command perform several attempts. To stop, type “CTRL” + “C”.

How do you interpret the results of the ping command?

Each line has different parts with the following meaning:

  • 64 bytes: The size of the test package.
  • If you ping a domain name for the test, the tool will identify the IP address of that domain.
  • ttl = 54: The “time to live” of your test. The TTL determines how long your package will travel before it falls dead.
  • Time = 9,488 ms: The time it took for 1 test package to be sent from your computer, to reach the destination and to come back.
  • 8 packets transmitted, 8 packets received, 0.0% packet loss – The number of packages sent and received and the % package loss.

Successful test
You have a continuous low response time – the time values ​​are close together. The number of packages sent and received is the same and there is no package loss. (It is not unusual for the first ping attempt to fail – this does not indicate a problem.)

There are issues
You have very different time values, timeouts and different package losses.

Unfortunately, the Ping command only tells you that there is a problem on the way. It does not tell whether the problem lies with your router, your internet service provider or your hosting. To find out, you must use the tracert (Windows) or Traceroute (MacOS).

Updated on 8 March 2020

Was this article helpful?