CLI – Have you ever run a command from the command line and afterwards wondered how long it took to run? If so, the time command will give you that answer.
This command measures the real, user, and system time used by a command during its execution.
The description of time in the macOS man page is:
The time utility executes and times utility. After the utility finishes,
time writes the total time elapsed, the time consumed by system overhead,
and the time used to execute utility to the standard error stream. Times
are reported in seconds..
As an example I ran a three ping against the site capmac.org and timed it.
To learn a lot more about how to use time, take a look at “Linux time Command Tutorial for Beginners (with Examples)“. Yes, this is a Linux article, but the time command as implemented on macOS is fundamentally the same. Check the macOS man page for time for all of the available options.