For developers

How to see CPU usage on a Mac

Updated · 4 min read

How to see CPU usage on a Mac with Activity Monitor, top and ps, and how Orrel totals each app's helper processes and flags what dev tools left running.

A Mac that has gone slow, a fan that will not settle, a battery that drains in an afternoon: the usual question is which app is responsible. macOS answers it with Activity Monitor, and Terminal answers it in one line.

Activity Monitor

Press ⌘Space, type Activity Monitor and press Return. It also lives in Applications › Utilities. Click CPU at the top of the window, then click the % CPU column header so the busiest processes come first.

View › All Processes shows everything, including macOS's own processes; My Processes narrows it to yours. To stop something, select it, click the stop button (✕) in the toolbar and choose Quit, or Force Quit if it does not respond.

Keep CPU on screen

The Energy tab

On a laptop, the Energy tab is often more useful than CPU. Energy Impact combines CPU, graphics, network and disk use into one relative figure, and the 12-hour Power column shows which apps have used the most over the day. It also shows whether an app is preventing sleep.

In Terminal

top is the live, text version of Activity Monitor:

top -o cpu

Processes are sorted by CPU and the list updates every second. Press q to quit. For a single snapshot of the ten busiest processes, take two samples, because the first one has no previous reading to compare against:

top -l 2 -o cpu -n 10 -stats pid,command,cpu | tail -n 11

ps gives a quick list sorted by CPU:

ps -Arc -o pid,%cpu,comm | head -n 11

On macOS, the ps figure is a decaying average over roughly the last minute, so it moves more slowly than top or Activity Monitor.

Reading what you find

How Orrel does it

Orrel's Running screen shows CPU and memory for the whole Mac at the top, with a short history graph, then three lists:

Per-process figures are a share of one core, as in Activity Monitor. The screen refreshes every two seconds while it is open. Localhost servers are listed too, with the project and the tool that started them; see how to find what is running on a port. The menu bar item shows those servers and any processes left running without opening the window.

Where Orrel stops

Orrel reads and stops your own processes only. macOS services and processes running as root or another user, including kernel_task and WindowServer, are not listed, so Activity Monitor with All Processes remains the place to see everything. Orrel has no Energy, Disk, Network or GPU view, no per-core graphs, and it does not put a CPU figure in the menu bar. macOS apps cannot be quit from Orrel.

Questions

Why does % CPU go above 100?

Activity Monitor and top measure % CPU against one core. A process using two cores fully shows 200%. The System, User and Idle figures at the bottom of Activity Monitor's CPU tab are for the whole Mac and add up to 100%.

What is kernel_task, and why is it using so much CPU?

kernel_task is macOS itself. When the Mac is warm, it deliberately takes CPU time so that other processes run less and the Mac cools down. You cannot quit it; closing heavy apps and giving the Mac airflow is what helps.

Why does Orrel show a different figure from Activity Monitor for an app?

Orrel adds up every helper process an app runs, such as each browser tab's process, into one row. Activity Monitor lists them separately. Orrel also samples at its own moments, so two readings taken a second apart can differ.