← Back to The Terminal says "command not found". What now?
How do I paste a command into the Terminal, and see that it worked?
Short answer
Search for Terminal, copy the command, click in its window, press Command-V and Return, then check it prints what its step says.
Before you start
You need a Mac, and a command to run from a source you trust, such as these help pages, GilbApp or Anthropic's own pages.
Words used here (2)
Steps
Search for Terminal and press Return.
Press Command-Space bar to open Spotlight, the Mac's search, type Terminal in the search field, then press Return to open the result Terminal. Terminal opens a window.
More about this
Terminal is the Mac's app for typing commands, lines of text that tell the computer what to do. If Terminal is open already, click its window instead. The answer on opening the terminal on your computer shows the other ways to open it.
Copy the whole command from the page that gives it.
Select the whole command on the page that gives it, and copy it. Copy a command exactly, all of it and nothing more: a missing or extra character changes what it does.
More about this
A line you paste stands on its own line in the steps of these help pages, with no full stop after it; a short word you type, such as claude, sits inside the sentence. Copy only the line, not the words around it.
Press Command-V in the Terminal window.
Click in the Terminal window, then press Command-V to paste the command. It shows on the line you type on, the command prompt, which Apple's guide shows ending in %.
More about this
Apple lists Command-V as Paste in Terminal's keyboard shortcuts; if a shortcut does not work, Apple says to look in the app menus in the menu bar.
Press Return.
Press Return. Terminal runs the command and shows what it prints in the same window.
More about this
Some commands take a while and show nothing while they work, such as the line that installs Claude Code; leave the window open and wait. To stop a command that is still running, click its window and press Control-C; this stops most commands.
Read what Terminal prints, and compare it with what the step says.
Read the last lines Terminal printed, and compare them with what the step that gave you the command says you should see. If they match, it worked.
More about this
For example, after the install line for Claude Code, Terminal says Claude Code successfully installed!. To check it, press Command-N for a new Terminal window, paste this line and press Return:
claude --version
It prints a version number followed by (Claude Code). If Terminal says command not found, check your spelling, as Apple advises, and paste the command again. For any other message, go back to the answer that gave you the command: it says what to do.
Deeper
Also asked:
How do I know the install worked? Terminal says Claude Code successfully installed!. To check, press Command-N for a new Terminal window, paste claude --version and press Return: it prints a version number followed by (Claude Code).
Terminal runs a command as it is written, so paste only commands from a source you trust, such as these help pages, GilbApp or Anthropic's own pages.
What a command prints when it worked differs from command to command, so each step that gives you a command says what you should see.
To close Terminal, choose Terminal > Quit Terminal in the menu bar. Terminal is outside GilbApp, so this answer has no pictures of it.
Apple makes Terminal and Spotlight, and may change them. This answer follows Anthropic's pages https://code.claude.com/docs/en/terminal-guide and https://code.claude.com/docs/en/setup, and Apple's own pages, all read on 12 November 2026: https://support.apple.com/guide/terminal/keyboard-shortcuts-trmlshtcts/mac, https://support.apple.com/guide/terminal/execute-commands-and-run-tools-apdb66b5242-0d18-49fc-9c47-a2498b7c91d5/mac and https://support.apple.com/guide/terminal/open-or-quit-terminal-apd5265185d-f365-44cb-8b09-71a064a42125/mac.
This answer is for a Mac. Windows and Linux are not covered yet.
Source: Apple's own pages, read 12 November 2026: https://support.apple.com/guide/terminal/keyboard-shortcuts-trmlshtcts/mac (Paste Command-V; look in the app menus in the menu bar to see the correct shortcuts), https://support.apple.com/guide/terminal/execute-commands-and-run-tools-apdb66b5242-0d18-49fc-9c47-a2498b7c91d5/mac (press Return; prompt examples ending in %; if you get the message command not found, check your spelling; Terminate commands: Press Control-C. This sends a signal that causes most commands to terminate.), https://support.apple.com/guide/terminal/open-or-quit-terminal-apd5265185d-f365-44cb-8b09-71a064a42125/mac. Anthropic's pages, read 2026-11-12: https://code.claude.com/docs/en/terminal-guide (Claude Code successfully installed!) and https://code.claude.com/docs/en/setup (claude --version; A working installation prints a version number such as 2.1.211 (Claude Code)). Live help pages, sentences shared word for word: How do I open the terminal on my computer? (steps 1-3: Command-Space bar, Spotlight, Terminal, Copy a command exactly ..., the command prompt, A line you paste stands on its own line ..., trust line, Control-C line, Quit Terminal, Mac-only line), How do I install Claude Code? (no progress while it downloads; leave the window open).
Checked against GilbApp d529620.