Sub topic 3
Launching apps and settings
This chapter covers Spotlight's most common job: opening apps and System Settings panes from the keyboard. It assumes you can open apps and use Finder, and that you know the basic keyboard shortcuts. The Terminal examples near the end assume you can run a command. Wording and layout differ a little between macOS versions, so check the labels on your own Mac.
Why launching is worth learning properly
Most people use Spotlight to open apps, and most of that use is slow. They type the full name, wait, and click. You can do the same thing with a few characters and one key press. Once Spotlight learns your habits, the result you want is usually already selected before you finish typing.
You will learn:
- how Spotlight ranks app results
- how to reach System Settings panes directly
- why an app sometimes fails to appear
- how to confirm what Spotlight sees from Terminal
The basic launch sequence
- Press Command-Space. The Spotlight search field opens.
- Type a few letters of the app name.
- Check that the first result is the app you want.
- Press Return.
Spotlight preselects the first result, called the Top Hit. Return opens whatever is selected, so you rarely need the mouse. Press the arrow keys to move to another result first if the Top Hit is wrong.
How Spotlight ranks app results
Spotlight matches your typing against the start of app names and against the start of each word in a name. It also remembers which result you pick for a given query and ranks that choice higher next time.
| You type | Likely Top Hit | Why it matches |
|---|---|---|
| `saf` | Safari | Start of the name |
| `act mon` | Activity Monitor | Start of each word |
| `term` | Terminal | Start of the name |
| `sys set` | System Settings | Start of each word |
Shorter queries work after a few uses. If you always pick Terminal when you type te, then te becomes enough. If the ranking puts the wrong app first, choose the right one a few times and Spotlight adjusts.
Matching is not strictly alphabetical. Two apps with similar names, such as a Microsoft Word installer and Word itself, can compete for the top spot. In that case, add one more letter or a second word before pressing Return.
Launching System Settings panes
Spotlight also indexes the panes of System Settings. Type the name of the thing you want to change, such as bluetooth, display, sound, or battery. The result opens System Settings at that pane, not at the front page of the app.
This saves time because the sidebar of System Settings is long, and its layout has changed between macOS versions. A search such as trackpad finds the right pane whether or not you remember where it lives.
You can also use Spotlight to open the app itself. On macOS Ventura and later, the app is named System Settings. In earlier versions, it is System Preferences. Searching settings works in both cases, since Spotlight matches on the word.
Browsing apps in recent macOS versions
Recent macOS releases, such as macOS Tahoe, add a way to browse apps from Spotlight without typing a name. You open Spotlight, then use a keyboard shortcut or the on-screen buttons to switch to a list of applications. The shortcuts vary by version. Hover over the buttons on the Spotlight window to see which shortcut your Mac uses.
This is useful when you cannot remember an app's name but know roughly what it does. In older versions, you can instead search by kind. For example, type kind:application to list applications.
Which apps Spotlight can find
Spotlight finds apps because they are bundles (folders that macOS treats as a single file) that carry metadata the index understands. Spotlight usually finds apps in these places:
/Applications/System/Applications, which holds built-in apps such as Calendar~/Applications, a per-user folder you create yourself/System/Applications/Utilities, which holds Terminal and Activity Monitor
Apps stored elsewhere, such as in Downloads or on a disk image, may appear too, but they are less reliable. If an app you downloaded does not show up, drag it into /Applications and try again.
Common errors when launching
- Command-Space does nothing. Another app has taken the shortcut. Launchers such as Alfred or Raycast often use the same keys. Check System Settings, then Keyboard, then Keyboard Shortcuts, then Spotlight. Also check whether Control-Space for input source switching is set up as you expect.
- An app is missing from results. The Applications category may be turned off in the Spotlight settings, or the app is not in an indexed location. The settings chapter later in this series covers categories. The troubleshooting chapter covers rebuilding the index.
- The wrong app opens. You pressed Return too early, before the ranking updated. Look at the highlighted row before you press Return.
- Two copies of the same app appear. You have an old copy in Downloads or in a backup folder. Delete or move the extra one.
- An old app name still appears. The index has not caught up with a rename or removal. This usually clears by itself, or after an index rebuild.
Checking what Spotlight sees from Terminal
Terminal gives you a second view of the same index, so you can tell whether a missing app is a Spotlight problem or something else. The mdfind command queries the Spotlight index. The chapter on Terminal tools covers it fully, but two short commands are useful here.
This command lists the apps in /Applications that Spotlight has indexed. The content type com.apple.application-bundle identifies an app bundle.
mdfind -onlyin /Applications "kMDItemContentType == 'com.apple.application-bundle'"If your app is in /Applications but absent from this list, the index is missing it, and the troubleshooting chapter applies.
The open command launches an app by name without Spotlight. It is a useful comparison: if open works and Spotlight does not, the app is fine and the index is the problem.
open -a "Activity Monitor"You can also open System Settings itself the same way.
open -a "System Settings"On macOS versions before Ventura, use System Preferences instead.
Turning launch behavior off or on
Spotlight settings control which kinds of results appear. If you want Spotlight to stop showing apps, or stop showing settings panes, you turn those categories off in System Settings, under Spotlight. The labels vary by version. Turn a category back on if launching stops working, since this is the most common reason that apps vanish from results after a settings change.
A short routine to practice
- Press Command-Space, type
act mon, and look at the Top Hit before you press Return. - Press Command-Space, type
bluetooth, and note which pane opens. - Pick a rarely used app, type its first two letters, and check whether it ranks first. Choose it a few times and check again.
Exercise
You press Command-Space, type term, and Spotlight opens a different app from the one you wanted. Name two things you can do to get Terminal, and one thing you can check if Terminal never appears at all.
Show answer
Add a letter or two (for example termi), or press the arrow keys to select Terminal before pressing Return. Picking Terminal repeatedly also teaches Spotlight to rank it first for term. If Terminal never appears, check that the Applications category is enabled in the Spotlight settings, and compare with mdfind -onlyin /System/Applications/Utilities "kMDItemContentType == 'com.apple.application-bundle'" to see whether the index knows about it.
Exercise
An app you just downloaded does not appear when you search for it, but open -a "AppName" launches it. What does that tell you, and what is the simplest first fix?
Show answer
The app itself works. Spotlight has not indexed it, or it sits in a location Spotlight does not cover well, such as Downloads or a disk image. The simplest first fix is to move the app into /Applications and search again. If it still does not appear, rebuild the index as described in the troubleshooting chapter.