Run a Traceroute on macOS

By Vinayak KokareUpdated Nov 26, 2026

How to Run a Traceroute on macOS Using Terminal 

 

If you are using macOS, you can use the Terminal application to run a traceroute and identify the network path that data takes from your Mac to a destination server. 

A traceroute helps you understand how network traffic travels from your computer to a specific website or server. It displays the routers and network devices that your data passes through along the way. 

Steps to Run a Traceroute on macOS 

Step 1. Launch Terminal 

3 formas rápidas de borrar el historial del portapapeles en Mac sin pérdida de datos

Open Finder and navigate to: 

Applications → Utilities → Terminal 

You can also use Spotlight Search by pressing Command + Space, typing Terminal, and pressing Return. 

Step 2. Enter the Traceroute Command 

How to Use Traceroute Command to Read Its Results

In the Terminal window, type the following command: 

 traceroute coolexample.com 

Replace coolexample.com with the domain name you want to trace, including its extension, such as .com, .net, or .org. 

Step 3. Press Return 

Encontrar seu endereço IP e executar um traceroute

Press Return on your keyboard to execute the command. 

The traceroute process will begin, and the results will appear in the Terminal window. 

Step 4. Understand the Traceroute Hops 

Reference 23.2 Use Terminal to Troubleshoot Network Issues | Troubleshoot Network Issues | Peachpit

Traceroute displays the network path between your Mac and the destination server. 

Each numbered line represents a hop, which is a router or network device that forwards your traffic to the next destination. 

The hops generally include: 

  • Hop 1: Usually your local router or network gateway. 

  • Intermediate Hops: Routers and network devices along the route taken by your traffic. 

  • Final Hop: The destination server, if it responds to the traceroute probes. 

Each hop typically displays the router's hostname or IP address and three response times in milliseconds (ms). 

These response times indicate how long packets take to reach that hop and return to your Mac. 

Note: If you see * * * for a hop, it means the router did not respond within the timeout period. This does not necessarily indicate a network problem because some routers block or deprioritize traceroute requests. 

Step 5. Wait for the Traceroute to Complete 

Provide Technical Support Team with Network Diagnostic Results

Wait until the traceroute process finishes. 

The trace is complete when the destination is reached or the maximum hop limit is reached, which is typically 64 hops on macOS. 

Keep in mind that the destination server may not respond even when your internet connection is working correctly. 

Step 6. Copy the Traceroute Results 

Browser Compatibility Checklist

To copy the traceroute output: 

  1. Select the traceroute results in the Terminal window. 

  1. Right-click and select Copy. 

  1. Alternatively, press Command + C on your keyboard. 

Step 7. Save the Traceroute Results 

安全公司釋出 MacOS 勒索病毒 ThiefQuest 免費解鎖工具,解鎖後務必再次清理系統 | LINE購物

Open a text editor, such as TextEdit. 

  1. Create a new document. 

  1. Paste the copied traceroute results. 

  1. Select File → Save. 

  1. Enter a file name. 

  1. Choose a location on your Mac and save the file. 

 

You have successfully run a traceroute on macOS and saved the results! 

Was this article helpful?