How to Open Terminal and Use Terminal on Mac
Oct 30, 2026 • Filed to: Solve Mac Problems • Proven solutions
⚡ Quick Answer: How to Open Terminal and Use Terminal on Mac?
Press Command + Space to open Spotlight Search, type Terminal, and double-click the app. Alternatively, open Finder > Applications > Utilities and double-click Terminal. Once open, type a command (such as ls to list files, cd to change directories, or rm to delete files) and press Return to execute it.
rm or sudo delete data permanently without the Trash. If you accidentally lose files while using Terminal, stop immediately and run Wondershare Recoverit for Mac to retrieve them.When people heard the word Mac Terminal, they get scared thinking that using Terminal is very hard. But the truth is quite the opposite. Once you get a hold of Terminal commands, it will become easy for you to carry out even the complex task on Mac easily. So, in this article, you will learn how to open and use Terminal on Mac.
Part 1. Basics of Mac Terminal:
Just like the Windows command line, Mac Terminal is the command-line system that helps the users to take control of the operating system and make changes in it. The best thing you can do to learn using Terminal is to start using it. The most important thing you need to learn is commands.
All you need to do is to type the command and hit Return to execute it. Every command has three components, the command itself, an argument, and an option. The command is self-explanatory; the argument tells the command the source where it should operate and the options work as a modifier for the output.
🔍 Anatomy of a Terminal Command
| Component | What It Does | Example |
| Command | The program or action to run, e.g. mv to move files. |
mv |
| Argument | The source and destination the command operates on. | file.txt ~/Documents/ |
| Option | A modifier that changes how the output behaves. | -v, -R |
For example, if you want to move a file from one folder to another, the command used will be- mv. Then type the location where the file exists and add file name and location where you want to move it.
While you are using the Mac Terminal, you should know about the basic rules too.
- Every single character matters in the terminal command, even spaces, and commas.
- You can't use a mouse or Trackpad inside the Terminal. Therefore, you'll have to navigate using the arrow keys, and Return key.
- Commands are executed inside a location, so if you don't specify a location in the command, it is automatically set to the recent or previously specified location.
Essential Mac Terminal Commands Cheat Sheet
| Command | Function |
ls |
List the contents of a particular directory. |
cd |
Change to another directory. |
sudo |
Authenticate as a superuser to gain extra security privileges. |
defaults write -g ApplePressAndHoldEnabled -bool false |
Disable the pop-up accent window while typing. |
defaults write com.apple.finder AppleShowAllFiles -bool TRUE |
Show hidden files in Finder. |
history |
Show the terminal command history. |
defaults write com.apple.SoftwareUpdate ScheduleFrequency -int 1 |
Check for macOS updates automatically. |
If we start learning, the macOS terminal commands won't come to an end. So, in this article, we will only learn using some basic commands like deleting files, show hidden files, change folder permissions, etc.
Part 3. How to Open Terminal on Mac:
There is no doubt that Terminal is a handy tool for Mac users. Therefore, it is vital that you know all the ways there is on how to open a terminal on Mac. Here are all the ways that are used to open Terminal. Take a look and use the one which suits you best.
6 Ways to Open Terminal on Mac
Method 1: Using Spotlight Search
- Click the Spotlight search button in the menu bar, or press
Command + Space. - Type
Terminalin the search field. - Double-click the Terminal result to open it.

Method 2: Using Finder
- Open Finder and click Go from the menu bar.
- Choose Utilities to open the Utilities folder.
- Double-click the Terminal application.

Method 3: Using the Applications Folder
- Open Finder and click Applications in the left side panel.
- Expand the Utilities folder.
- Double-click Terminal to launch it.

Method 4: Using Launchpad
- Open Launchpad from the Dock, or press the
Fn + F4keys. - Look for the Other folder, which contains Terminal by default, or type
Terminalin the search box. - Click the Terminal icon to open it.

Method 5: Using Siri
- Open Siri from the menu bar or the Applications folder.
- Say "Open Terminal" and Siri will launch it for you.

Method 6: Create a Terminal Shortcut
- Right-click the Terminal application in Utilities or in the recent applications list in the Dock.
- Hover over Options in the pop-up window.
- Choose to Keep in Dock, Show in Finder, or Open at Login.

All of these methods are simple and easy. So, pick whichever is more comfortable and you will be able to access Terminal with just one click.
Part 4. How to Use Terminal Commands on Mac:
Here is a list of some common commands used in Terminal. These commands will provide you a short and precise method to carry out the task.
Common Terminal Tasks and How to Run Them
1. Delete Files Using Terminal
Use the rm command to permanently delete files and folders without the Trash.
- Launch Terminal and type
cd ~/Desktopto move to the desktop directory. - Type
rm MyFile.rtf(replaceMyFile.rtfwith your file name) and press Return. The file is gone forever. - To delete multiple files, leave a space between file names, e.g.
rm file1.txt file2.txt.
2. Open Finder from Terminal
The open command lets you open Finder even when the OS is acting up.
- Type
pwdto print the working directory path (e.g./Users/admin). - Type
cdto change directories as needed. - Type
open .and press Return — a Finder window will open in the current folder.
3. Show Hidden Files with Terminal
- Run
defaults write com.apple.finder AppleShowAllFiles -bool TRUE. - Run
killall Finderto restart Finder and apply the change. - To reverse the process, change
TRUEtoFALSEand runkillall Finderagain.
4. Empty Trash Using Terminal
- Type
sudo rm -R(do not press Enter yet) and control-click the Trash icon to open it. - Select the files you want to delete and drag them into the Terminal window.
- Press Enter and enter your admin password. Press Enter again — the Trash files are deleted.

5. Change Folder Permissions
Use the chmod command to control read, write, and execute permissions for user, group, and others.
- Type
cdand drag the folder whose permissions you want to change into Terminal to copy its path. - Type
ls -lto reveal all subfiles, subfolders, and their permissions. - Type
chmod 755 /bin(adjust the number and path as needed) to apply the new permissions.

6. Repair Disk
- Type
diskutil repairVolume /to repair the startup disk. - For other volumes, run
diskutil repairVolume /Volumes/ExternalBackups/and press Return. - Wait for the repair command to resolve all issues on the disk.
Pro Tips for Using Terminal on Mac
- Change screenshot format: Run
defaults write com.apple.screencapture type JPGto switch screenshots to JPG, PNG, TIFF, or other formats. - Create a recent applications folder: Run
defaults write com.apple.dock persistent-others -array-add '{ "tile-data" = { "list-type" = 1; }; "tile-type" = "recents-tile"; }';killall Dockto add a recents tile to the Dock. - Flush Mac memory: Run
sudo purgeand enter your password to clear the Mac memory. - Repair the file system: Run
fsck -fyand press Return to check and fix disk consistency. - Keep your Mac awake: Run
caffeinate, or specify a duration such ascaffeinate -t 3600to keep it awake for a limited time. - Recover lost files: If a command mistake costs you data, Recoverit for Mac can retrieve lost or deleted files with one click.
Part 5. Tips for Opening and Using Terminal on Mac:
Here are some tips for opening and using a Mac terminal so that you can avoid common mishaps.
- To change the default format of an image screenshot, type - defaults write com.apple.screencapture type JPG and hit Return. You can change to format to any format like PNG, TIFF, etc.
- To create a recent applications folder on Mac, type- defaults write com.apple.dock persistent-others -array-add '{ "tile-data" = { "list-type" = 1; }; "tile-type" = "recents-tile"; }';killall Dock. As you control-click the Dock item, you'll see the recent application, documents, servers, and favorite items all in one place.
- To flush the Mac memory, type- sudo purge and you might be asked to enter a password. Enter the password and the Mac memory will be erased.
- To fix your Mac, you can use File System Consistency Check, i.e. fsck, and repair the file system on Mac. Type- fsck fy and hit the return key. A bunch of code will appear on the screen until the check finishes and you will see the results on the screen in a while.
- Use caffeinate to keep your Mac from falling asleep as- caffeinate and hit the return key. You can also specify the amount of time in seconds like –t 3600 or –t 24000 to keep your Mac awake for a limited time period.
If you somehow end up making a mistake while using the Terminal and end up losing your files, then you still have an option to get them back. If you use Recoverit data recovery software for Mac, you can retrieve all files that are lost or deleted from Mac with just one-click.
Closing Words:
In this article, we learned how to open and use Mac Terminal in detail. As the commands and use of Terminals extend to the limit of words of this article, you can always learn a new thing. All the things you have learned from this guide will surely come in handy. And if you happen to fall prey to data loss situations, then you will still have access to Recoverit Mac Data Recovery to get the important files back on the device. Recommend this Mac Data Recovery tool to your friends and family and help them to retrieve their lost or deleted files.
People Also Ask
-
How do I open Terminal on a Mac?
PressCommand + Spaceto open Spotlight, typeTerminal, and double-click the result. You can also open Finder > Applications > Utilities and double-click Terminal. -
What is the basic command to delete a file in Mac Terminal?
Use thermcommand followed by the file name, for examplerm MyFile.rtf. This permanently deletes the file without sending it to the Trash, so be careful and back up important data first. -
How do I show hidden files in Finder using Terminal?
Rundefaults write com.apple.finder AppleShowAllFiles -bool TRUE, thenkillall Finder. To hide them again, changeTRUEtoFALSEand runkillall Finderonce more. -
Can I recover files deleted with Terminal on Mac?
Yes. Stop using the Mac immediately and run Wondershare Recoverit for Mac. It scans the drive for lost or deleted files and restores them with one click.
What's Wrong with Mac
- Recover Your Mac
- Recover your data for free.
- What is New in MacOS 13 Ventura?
- Back Up Macbook Before Upgrade
- How to Downgrade MacOS System
- Files overwritten? Recover it.
- Top 5 Mac recovery tools.
- Get USB drive files on Mac.
- Recover a formatted SD card.
- Fix Your Mac
- Mac won't turn on? Solved.
- Know and fix kernel panic.
- You installed macOS anyway.
- Force quit Mac to fix issues.
- Make frozen Mac responsive.
- Delete Your Mac
- Delete files and folders.
- Do Ctrl Alt Delete on Mac.
- Format USB to FAT32.
- What's Other on Mac?
- 3 ways to format your Mac.
- Learn Mac Hacks
Recoverit Editorial Team
chief Editor