How to Run a Ping Test: Step-by-Step Guide for Beginners
By PingTester · August 10, 2026 · 8 min read
The ping command is the oldest and most universally available network diagnostic tool. It exists on every desktop operating system, every router, and nearly every embedded device. Despite its age, ping remains the fastest way to answer a simple question: "Can my device reach this host, and how long does the round trip take?"
This guide walks through running ping on Windows, macOS, and Linux, decoding every field in the output, and knowing when a result means trouble.
What Is Ping and How It Works
Ping uses the Internet Control Message Protocol (ICMP) to send an "echo request" packet to a target host and waits for an "echo reply." The time between sending the request and receiving the reply is the round-trip time (RTT), reported in milliseconds.
Unlike TCP-based tools, ICMP does not open a connection or establish state — there is no handshake. This makes ping a clean measure of pure network reachability and latency, independent of application-layer behavior. The trade-off is that some networks block ICMP for security or policy reasons, so a failed ping does not always mean a host is down; it may mean ICMP is filtered. For more on the protocol differences that affect what you measure, see our TCP vs UDP latency comparison.
Running Ping on Windows
On Windows, ping is available from the Command Prompt or PowerShell.
- Press
Win + R, typecmd, and press Enter. - At the prompt, type:
ping example.com - Press Enter. Windows sends four echo requests by default and prints a summary.
C:\> ping example.com
Pinging example.com [93.184.216.34] with 32 bytes of data:
Reply from 93.184.216.34: bytes=32 time=14ms TTL=56
Reply from 93.184.216.34: bytes=32 time=13ms TTL=56
Reply from 93.184.216.34: bytes=32 time=14ms TTL=56
Reply from 93.184.216.34: bytes=32 time=13ms TTL=56
Ping statistics for 93.184.216.34:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 13ms, Maximum = 14ms, Average = 13ms
Useful Windows flags: ping -t example.com pings continuously until you press Ctrl+C, ideal for monitoring. ping -n 10 example.com sends exactly 10 requests instead of the default 4.
Running Ping on macOS and Linux
On macOS and Linux, ping is run from the Terminal. Unlike Windows, it runs continuously by default until you stop it with Ctrl+C.
- Open Terminal (macOS: Cmd+Space, type "Terminal"; Linux: usually Ctrl+Alt+T).
- Type:
ping example.com - Press Enter. Ping will run continuously. Press Ctrl+C to stop and see the summary.
$ ping example.com
PING example.com (93.184.216.34): 56 data bytes
64 bytes from 93.184.216.34: icmp_seq=0 ttl=56 time=14.2 ms
64 bytes from 93.184.216.34: icmp_seq=1 ttl=56 time=13.9 ms
64 bytes from 93.184.216.34: icmp_seq=2 ttl=56 time=14.1 ms
64 bytes from 93.184.216.34: icmp_seq=3 ttl=56 time=13.8 ms
^C
--- example.com ping statistics ---
4 packets transmitted, 4 received, 0.0% packet loss
round-trip min/avg/max/stddev = 13.8/14.0/14.2/0.2 ms
To send a fixed count and exit automatically, use ping -c 4 example.com. To set an interval, use ping -i 2 example.com (2 seconds between requests). Note that intervals below 0.2 seconds typically require root privileges.
Understanding Ping Output: Bytes, Time, TTL
Each line of ping output packs several diagnostic signals:
- bytes — the size of the ICMP payload. Default is 32 bytes on Windows, 56 on macOS/Linux. A mismatch can indicate a path with a restrictive MTU.
- time — round-trip latency in milliseconds. This is the headline number most people care about.
- TTL (Time To Live) — a hop counter that decrements at each router. It starts at the sender's initial value (commonly 64, 128, or 255) and decreases by 1 per hop. A low TTL means many hops; a TTL of 0 means the packet was dropped. Comparing the received TTL to common initial values lets you estimate the number of hops the packet took.
- icmp_seq — the sequence number of the echo request. Gaps in sequence numbers indicate lost or reordered packets.
Interpreting Results: Good vs Bad Latency Values
What counts as a "good" ping depends on what you are doing. As noted in connectivity research from grahammiranda.network, average latency below 20ms is excellent for most applications, while anything above 150ms may noticeably impact real-time services.
General reference ranges:
- < 20 ms — Excellent. Suitable for competitive online gaming, high-quality VoIP, and real-time collaboration.
- 20-50 ms — Very good. Comfortable for most gaming, video calls, and remote desktop use.
- 50-100 ms — Acceptable. Noticeable in fast-paced gaming; fine for general web use, streaming, and most voice calls.
- 100-150 ms — Marginal. Voice and video calls work but with perceptible delay; gaming becomes difficult.
- > 150 ms — Poor for real-time use. Web browsing and downloads still work, but real-time apps degrade.
- > 300 ms — Satellite or heavily congested paths. Interactive use becomes frustrating.
Consistency matters as much as the average. A connection averaging 30ms but ranging from 10ms to 90ms will feel worse than one steadily at 35ms. The stddev field on macOS/Linux ping quantifies this jitter.
Continuous Ping (-t Flag) for Monitoring
Single-shot ping tells you about one moment; continuous ping tells you about the connection over time. On Windows, ping -t runs until interrupted. On macOS/Linux, ping runs continuously by default.
Continuous ping is invaluable for diagnosing intermittent issues — a network that is fine 95% of the time but drops packets every few minutes will look healthy in a 4-request default ping but reveal itself within a minute or two of continuous monitoring. Let continuous ping run for several minutes during the period when you experience problems, then review the summary statistics. Patterns like periodic spikes (every 60 seconds, for instance) often point to a router rebooting or a background backup saturating the link.
Ping Statistics: Min, Avg, Max, Packet Loss
The summary at the end of a ping run is where the most useful diagnostic information lives:
- Minimum — the lowest RTT observed. Useful as a baseline of what the connection is capable of under best conditions.
- Average — the mean RTT. The headline number, but it can hide spikes if the variance is high.
- Maximum — the highest RTT observed. A max much larger than the average indicates jitter or momentary congestion.
- Packet loss percentage — the fraction of requests that received no reply. Anything above 0% on a stable connection warrants investigation; above 1% is noticeable in real-time apps; above 5% is severely disruptive.
For a structured approach to interpreting and acting on packet loss figures, see our guide on diagnosing packet loss.
Common Ping Errors
Ping output is not always a clean reply. Two error messages appear frequently:
Request Timeout
"Request timeout" (Windows) or "no reply" (macOS/Linux) means no echo reply arrived within the wait window. Causes include ICMP being filtered by a firewall, the destination being unreachable, severe congestion dropping the reply, or the host being powered off. Repeated timeouts across many targets indicate a local problem; timeouts to one specific target usually mean that target or its network is filtering ICMP.
Destination Host Unreachable
This error means a router along the path explicitly told your device it cannot route to the destination. It typically indicates a routing problem — no valid path exists from your network to the target, often because of a misconfigured route table, a downed peering link, or the destination network being offline. This is distinct from a timeout: a timeout is silence; "destination unreachable" is an explicit rejection.
Summary
Ping is the universal first-step network diagnostic. Run it from a terminal on any OS, read the time, TTL, and packet-loss fields, and compare against realistic thresholds: under 20ms is excellent, above 150ms is poor for real-time use. Use continuous ping to catch intermittent problems, and pay attention to the summary statistics — average, max, and loss percentage — not just individual replies. When ping fails, distinguish silence (timeout) from an explicit unreachable message, since they point to different root causes.
References & Resources
- ICMP protocol reference and ping command documentation — authoritative reference for ICMP echo request/reply behavior and ping flag semantics across platforms.
- Network troubleshooting guide for home connections — practical walkthrough for diagnosing common home-network issues using ping and related tools.