How to Test Internet Speed in the macOS Terminal Using the networkQuality Command

When your internet connection feels sluggish, the immediate instinct is to open a web browser and navigate to a popular speed testing website. While these third-party tools are convenient, they are often bloated with advertisements, tracking scripts, and heavy graphical interfaces that can slightly skew the actual results, especially on older machines.

If you are using a modern Mac running macOS Monterey (macOS 12) or later, you do not need to rely on external websites. Apple has silently integrated a native, highly accurate internet speed testing tool directly into the macOS command line. This tool is called networkQuality.

What is the networkQuality Command?

The networkQuality command is a built-in utility that measures your internet connection’s upload and download speeds by communicating with Apple’s Content Delivery Network (CDN) servers. Because it is executed entirely within the Terminal, it uses minimal system resources and provides a pure, raw measurement of your network’s capabilities.

Furthermore, this tool does not just measure raw speed; it evaluates your network’s “responsiveness.” Responsiveness measures the quality of your connection when multiple devices are heavily using the network simultaneously (often referred to as Bufferbloat). This is critical for understanding why video calls might lag even if your raw download speed is high.

How to Run a Basic Speed Test

Running the test requires no setup or installation. You only need to open your terminal application.

  1. Open the Terminal app. You can find it by pressing Command + Space to open Spotlight Search, typing “Terminal”, and pressing Enter.
  2. At the prompt, type the exact command: networkQuality
  3. Press Enter.

The test will begin immediately. You will not see a loading bar; instead, the terminal will pause for several seconds as it executes the upload and download tests in the background.

Once completed, it will print a brief summary report detailing:

  • Uplink capacity: Your upload speed, measured in Megabits per second (Mbps).
  • Downlink capacity: Your download speed, measured in Mbps.
  • Responsiveness: Graded as Low, Medium, or High.

How to Run Sequential Tests

By default, the standard command runs the upload and download tests simultaneously. This simulates real-world stress but can sometimes result in slightly lower peak speeds than what your Internet Service Provider advertises.

If you want to test your maximum theoretical download speed without any upload interference, you can tell the utility to run the tests sequentially (one after the other) by adding a specific flag.

Run the following command:

networkQuality -s

This will execute the download test, finish it, and then execute the upload test, giving you isolated metrics for each direction.

How to View Detailed Network Data

If you are a network administrator or need to provide technical logs to your ISP, the standard summary might not provide enough information. You can force the command to output verbose, highly detailed JSON data.

Run the following command:

networkQuality -c

This will output a large block of JSON code that includes specific latency measurements in milliseconds (ms), the exact servers the test communicated with, and detailed responsiveness scores for both the uplink and downlink connections independently.

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.