How To Access Terminal On Mac – 5 Easy Ways (Updated Guide for 2022)

In this guide, we will show you everything you need to know about how to access terminal on mac, so keep reading!

Below you can find out 5 different methods to access terminal on mac,

Method 1 – Mac Os – How To Open Terminal (Command Prompt) On Mac

Hi guys in this video im going to show you how to open the terminal window on macbook as we. Know that mac operating system is built on new unix so sometimes there is a requirement to open the terminal. Window and from the unix commands for example to do some installations and things like that there are two ways. To open the terminal window first one is to go to the launch pad down here just click on that.

And then go to other here once you click on another you will be able to see this terminal i. Can just click on that and the terminal window will open for you here you can write down the unix. Commands and execute them the second and the most easiest way to open the terminal window is to go to. This magnifying glass on the top right corner this is called spotlight search once you click on that and put. In terminal in the search field the terminal window option will come on top just click on that and it.

Will open the terminal window for you so these were the two ways to open the terminal window i hope. You liked the video and dont forget to subscribe to the channel thank you.

Method 2 – Absolute Beginner Guide To The Mac Os Terminal

Get everyone im percy from top tech skills comm and today were taking a look at the terminal i think. Being effective in the terminal is an absolutely necessary skill for all developers if you cant use it effectively youre. Going to be limited to gui tools or youre going to spend hours doing something that should take you minutes. In this video im gonna give you an absolute beginner introduction to the mac os terminal also called the command.

Line alright lets jump in so here we are in mac os we currently have nothing open but we want. To jump straight into the terminal ive got it in my dock if you dont have it in your dock. You can find it in the utilities folder im gonna open up by clicking on it drag it to make. It slightly bigger and lets have a look at what we can see in terminal on the left hand side. We have whats called the prompt this is going to be slightly different from computer to computer but in general.

Its going to end in a dollar sign if youre doing tutorials online and they give you some examples of. Things to doing the command line usually theyll represent this whole prompt with the dollar sign so i see a. Lot of beginner developers copy the dollar sign as well thats not right you should just copy what comes after. Because the dollar sign just represents this prompt on the right hand side we have whats called the cursor this. Little gray square and that just shows where you can start typing im gonna start typing there and you see.

It pop up on the screen ill delete all that and in order to get started with the terminal lets. Find out where we are and well open up a finder window so we can actually see whats going on. To find out where we are in the terminal were going to use a command called pwd which stands for. Print working directory so ill hit enter now and youll see that the directory its printed out is the top. Tech skills directory within the users directory in order to visualize a little bit better because youre just getting started.

With the terminal im going to open this directory ive copied that with command c so command c there and. Ive pasted it in the terminal with command v ill hit enter here to open it and youll see a. Little finder window pop up to the right-hand side so what we see on the right hand side is actually. Where we are in the terminal the big difference being that in find out we can actually see all of. The directories where we are but in terminal we cant so lets do that in the terminal lets see what.

We have in the directory that we currently are were going to use a command called ls which is short. For lists if i type ls and hit enter youll see that it prints out all of the directories in. The directory we are now and youll if you count them up and have a look at them youll see. That they match up totally to what we have here in find out we have applications desktop documents etc you. Can see here applications desktop documents so now that we can see that we have the same directories here lets.

Move between them using the terminal in finder the way that wed move between directories is potentially to double click. It depending on your view setting up here so im going to navigate into the movies directory in finder ill. Double click it in the terminal how would we do this we use a command called cd cd is short. For change directory so since ive changed the movies directory in finder lets also do that in the terminal cd. And im going to type out movies and we get some feedback here we can see that the tilde has.

Changed to movies which shows that weve changed directory but lets use a command that weve already studied to work. Out if weve actually changed directories and a type pwd hit enter and youll see yes we are in the. Movies directory inside top tech skills inside users and in finder we can see that we have three video files. In there mk vs and we also know a command that will allow us to confirm what files we have. In the terminal and type ls hit enter and youll see that those three movies come up when we hit.

Ls so now lets go back to where we were in finder wed hit the back button and that would. Take us to the parent directory here in the terminal how would we do this well there are a couple. Of different ways but im going to show you a way that is the quickest in the terminal what were. Going to do to go back up to the previous directory is do cd dot dot ill hit enter there. Type pwd to confirm where we are and you can see yes weve moved out from the movies directory to.

Back to the top tech skills directory so you might be a little bit confused what actually means well dot. Dot means the parent directory of the current directory that were in so if we were to run that again. For example in our top tech skills directory here if i typed cd dot dot i would expect it to. Take me to the users directory ill give it a try cd dot dot and now if i type pwd. Youll see yes weve actually changed to the users directory from top tech skills theres another little one that is.

Cd dot now if we run that and we type pwd again youll see that we havent changed directory at. All and thats because dot means the current directory so what weve done by typing cd and then dot is. Weve told terminal to change to our current directory which will have no effect so that dot dot and the. Single dot are little shortcuts to reference the parent directory or the current directory my screens become a little bit. Messy with all these commands so what im going to do at the moment is type clear to clear my.

Screen and we have a nice clean screen here so if youre wondering where all your stuff went its just. Been pushed down but sometimes youll be in a situation where you just like the screen to be clean again. So you can focus and thats what the clear command is for theres another way to do that on a. Mac you would hit command k so im going to type pwd to get some output again and if i. Hit command k youll see that it has the same effect as running clear now this is a really useful.

Little shortcut that i use pretty frequently now lets start making some files before i make some files because im. Currently in the users directory i want to change back to the directory where we started which is the one. That we have opened in finder over here our top tech skills directory and users a quick way to change. Back to our home directory which is the users top tech skills directory is to use another little shortcut in. The terminal which is tilde io type cd and then tilde now if youre not familiar with tilde you can.

Access that by holding shift and pressing the key to the left of your one key and thats going to. Print this little tilde now if i hit enter youll see that weve changed to tilde over here and what. This represents is when you hit pwd the top tech skills directory it means the home directory of the user. Thats currently logged in im gonna hit command k to clear the screen and were back to a nice clean. Screen lets create a new file to create a new file were going to use the touch utility im going.

To type touch and then test underscore file.txt hit enter as you can see in the finder window weve had. A new file appear their test file dot txt will confirm that in the terminal by typing ls the command. We studied before hit enter and yep you can see at the end we have test file dot txt appear. There if we type open test and then if i hit tab here youre going to see something pop up. You can see that the rest of the file name has completed itself thats called tab completion if you start.

Typing a file or folder in your terminal and its specific enough that the terminal knows exactly what youre talking. About it can autocomplete what youve typed so just as a quick example if i typed open and then p. And hit tab nothings going to come up and thats because we have both pictures and public in there and. Terminal doesnt know which one to actually go to if i hit tab again its going to show us the. Two options now if i type p i none of the other directories start with p i and if i.

Hit tab again its going to autocomplete two pictures so thats tab completion thats a pro tip for you thats. Gonna save you a whole lot of time and prevent a whole lot of mistakes so because theres only actually. One file starting with p interest i p– t and hit tab its going to autocomplete test file dot txt. It entered to open it and youll see it opens up here in textedit im going to type a little. Message here hello world im gonna save it with command s quit out of here with command q so the.

Reason i showed you that is im going to demonstrate a little tool in the terminal that you can use. To quickly edit text files or any file that is like text like html right in the terminal so were. Going to use a little tool called nano to open up the test file again im just going to type. T hit tab enter and youll see that our nice little nano editor has popped up in our terminal now. Im going to tell you that you shouldnt be using the mouse in here if ice like this and start.

Pressing delete with the selection its not going to work its only based off the cursor that little gray thing. That you see moving around there so im gonna hit enter at the end of the line and type another. Message to prove that we can actually edit a file within nano ill type hello top tech skills exclamation mark. Now command s isnt going to work down here so well look at the commands at the bottom of the. Screen so whats this this little hat here is called a carrot thats the name of the character but what.

That represents on your keyboard is the ctrl key so not the command key on a mac the ctrl key. Ctrl g forget help control over write out which actually means save ctrl arthur read file etc so what we. Want to do right now is we want to save so im gonna hit ctrl o and youll youll see. That nano has asked us for what file name we want to save it as because we dont want to. Create a duplicate we want to overwrite the file name that it gives us is going to be fine ill.

Hit enter and youll see that it wrote two lines which means it saved our two line file were going. To exit out of nano by hitting ctrl x and there we go were back to the terminal so lets. Confirm that we actually edited our file lets open it up again with our text editor now i can see. That two commands ago ive run the open command with test folder txt and thats exactly what i want to. Do now its a little pro tip for you again if you want to move through your history in the.

Terminal hit up so ive just hit the up arrow key and youll see that its taken me to the. Previous command if i hit up again its going to take me to the command before that hitting down moves. Back down and eventually im back down to the blank command line so its a really quick way to just. Navigate through the history of your commands and if you actually want to see what this is scrolling through you. Can use the history command if i hit enter here youll see that i have all of my previous commands.

In there and thats what im moving through so if i died by a history 98 there 97 there is. Nano and then open so this is the command that i want to run and actually let me just clean. That up hit command k as we studied before oh test file dot txt now you can see that the. Little alert that we wrote in there first is there and the one that we added in nano is also. There so that just demonstrates that you can also edit text files directly in the command line very quickly and.

Easily click command q to exit out of that and command k to clear my screen so we dont really. Have any need for the test file anymore lets delete it to delete a file were going to use the. Rm tool our m stands for remove rm and then well start typing test and again well hit tab to. Autocomplete it hit enter and youll see in the finder window over here our test file has disappeared well confirm. In the terminal by running ls and youll see that test file is no longer there where it was previously.

Lets start playing around with directories how would we make a directory in here im gonna type mkdir which is. Short for make directory and im going to call it test underscore directory hit enter and youll see that test. Directory has popped up in the right-hand side in our finder window lets confirm that in the terminal by running. Ls the command we saw before and yes youll see that test directory has appeared in there so lets use. The tools we learned before to manipulate stuff within test directory without changing into it so based on what we.

Learned before we know that we could go cd test hit tab to change into test directory and we could. Touch test file dot txt now we can see and find out what weve done here is that weve created. A test file within test directory well ls here to confirm that and pwd to confirm where we are now. We dont need to change into that directory to create that file in the terminal so what well do is. Well remove that file with rm like we learned before rm stands to remove remove test file dot txt and.

What were going to do is were going to go back up to the directory where we were cd dot. That we learned before which is going to take us up one directory pwd to confirm where we are ls. To confirm what we can see so what i want to do is i want to use touch but i. Want to create a file and test directory from here what im going to its going to start typing test. Hit tab thats going to autocomplete test directory now im going to type test file txt hit enter and youll.

See that in finder weve had the test file get created within test directory and we can check that from. Here if we type ls with nothing behind it its going to show us our current directory lets type ls. And thence type test directory all right so ive just auto completed that with tab hit enter so we can. Create files we can list files from within another directory what were going to do as well is were going. To use mkdir to create another directory within test directory so ive typed mkdir test directory forward slash and well.

Call this test directory to hit enter youll see immediately in finder over here test directory 2 has appeared within. Test directory and we can do all of the things that we did before we can open the file with. Open test directory forward slash test and youll see i hit tab there and because ive got something that starts. With test underscore terminal doesnt know which one i want to open ill hit tab again to see the options. That its giving me and i want to open test file not test directory so ill hit tab there to.

Open test file youll see that that comes up in our text editor lets just type some junk in there. Save quit and well open up with nano as well test directory i hit tab fold slash test underscore f. Tab and youll see there in nano we have opened the same file im going to quit out of that. Without saving ill just hit control x directly no changes so its not going to ask me to save so. The reason that ive shown you that is to show you that within the terminal you dont actually have to.

Be in a directory in order to deal with the files you just have to tell the terminal how you. Want to access the file so now that weve done all that i want to delete the test directory and. Obviously i want to delete whats inside it as well so i want to delete test directory – and test. File when i delete test directory so we studied rm before our and then well tie up test underscore directory. Hit enter and weve received an error message so our m is very helpfully telling us that test directory is.

A directory so what that means is that weve typed the wrong command rm when youre deleting a directory expects. An option so were going to type the option – r which stands for recursive and thats the way we. Delete directories rm – i will type test directory hit enter and youll see in finder our folder and all. Of the containing files and folders have been deleted and a word of warning rm does not send stuff to. The trash it actually deletes it directly so be very careful with it or just to leave things that you.

Know that you dont need to get back and now were back to where we started were in the top. Tech skills directory we have all of our test files and test folders have been deleted and weve done a. Full circle so i hope that you are now comfortable with navigating around your computer creating editing deleting files and. Doing the same with folders thanks for watching i really hope you found that video useful feel free to comment. Below with any questions or feedback if you enjoyed the video please give it a like and subscribe to our.

Channel if youd like to see more videos from top tech skills com thanks again and see you next time.

Method 3 – Mac How To Open Terminal Window

Hello and welcome to my video where i will show you how to open the terminal window on your mac. Two methods ill show you the first one quick and easy the second quick and easy as well and it. Will actually show you where the application resides so let me show you the first way you simply go to. The top right of your screen look for the magnifying glass icon which is the spotlight search click that and.

Type in terminal like so and you will see the terminal window is here okay so thats method one quick. And easy you can close that window the second method is to go to the location of the terminal application. To get there make sure we have the finder menu so you have no other application selected click on go. Scroll down to utilities open up utilities and youll see towards the bottom you have terminal so you can just. Double click that and you get exactly the same result the terminal window opens and from here you can do.

An ifconfig or use it for whatever means or reasons you have so i hope that helps you thank you. Very much for watching appreciate you choosing my video please leave a thumbs up if it has helped and i. Wish you a good day thank you.

Method 4 – How To Use Terminal On Your Mac – Command Line Beginner’s Guide

Everyone in todays video i wanted to talk about the terminal application or the command line application inside of your. Mac and this is a very useful and powerful way to basically type in some codes in this page to. Basically control your mac on the back end so things like the finder for example are a nice visual way. To get around your mac create folders a lot of us know how to do things on here using finder.

Using your visual representation on the mac but to terminal let you go on the back end and change some. Things on your mac thats not possible to do visually but were gonna really simplify it and focus on some. Really useful things and just navigating the terminal so lets go ahead and launch the terminal for the first time. So we start with a clean page and then ill show you some useful commands here that you could explore. And just about anything you could imagine on your mac you could google it and find the right terminal code.

Like making the dock disappear or remotely signing in to your computer there are commands for that that you could. Use terminal for so let me go ahead and quit terminal and well use the finder to find our terminal. We want to go to application the folder here on finder and there should be a folder called utilities double. Click that and inside of utilities there is an app called terminal go ahead and double click that and it. Will launch this terminal for you so let me go ahead and minimize the finder and make the terminal window.

Bigger and before i show you whats going on here lets go up here to shell and show inspector or. Command i here and im gonna change the profile here go to profile and change how the terminal looks so. Now let me close this and let me press command + to make this a little bigger so you can. See what im doing here so when you launch terminal youll see the last time you logged into terminal which. Was recently here for me and youll see this code basically its gonna tell you the name of the computer.

And then its gonna show you the home directory so let me just show you what this is on finder. Let me launch finder here and this right here is what this is showing so you see this is exactly. The same thing as this and this is what im looking at on the same page im going to how. To create folders and files and how to navigate inside of terminal just like you would not find her but. Before i do that let me just show you all the possible codes here inside a finer so press scape.

Twice if you got a little noise just go ahead and press it twice again and then press y for. Yes and then these are all the different possibilities its only showing you a few of them but if you. Press enter here on the bottom you could continue to press return to see all the possibilities of the short. Codes that you could put inside of your terminal so this command line right here is gonna give you all. Those options so go ahead and explore this a little bit im gonna link in the description to my website.

Where im gonna list all these for you so its a little bit easier to find exactly what youre looking. For and a little better organized lets say when youre done looking at this you could just go ahead and. Press delete and then youll be back exactly to where you started and a useful code here is if you. Type in clear and press return its gonna basically clear the page for you technically if you scroll up its. Gonna be everything that youve looked on terminal but this is a nice way to clear the terminal page here.

So again im back to the home directory so now i could show you some useful commands like creating folders. And files here so the very first command i want to show you is ls so type in ls and. Press enter and what this command does it lets you look inside of a folder here so right now im. Inside the home directory so thats where i could see right here my name here with the dollar sign and. When i press ls it shows you all the directories all the folders inside of that so let me show.

You on the finer the same exact thing so on the finder window again im here i selected this thats. The exact same thing that you see here on terminal and ls basically shows you all these so you can. See application creative cloud desktop in the exact same order that you see them here and then after i press. Enter it took me to the next line and its ready for the next command so lets go ahead and. Use the next command to create a folder here so the way to do that is to type in mk.

Dir so make a directory press spacebar and the name of the folder that you want to create so ill. Name this folder 1 and then ill press enter and now to double check that this took place let me. Go to the visual finder window and as you could see here it created folder 1 let me go ahead. And delete this on finder here so i could show you let me just put this on the side so. You could see it get created in real time here so ill type mkdir folder 1 enter and as you.

Can see right there in real time we created a for me so now that we have this folder that. We created with terminal lets look inside of that so to do that well put cd and then the name. Of the folder so folder 1 enter and now were inside of the folder 1 so look at the file. Structure here so here we were on the home page now we change it that were inside of the folder. 1 inside of the home page now that were inside of that folder lets create an actual file not a.

Folder but an actual file inside of that folder so in order to create a file theres a command called. Touch just spelled regular touch here after touch spacebar and then type in the name of the file so if. You want to call this just test dot html for example we could do that press enter and its created. That for us lets do a couple more here touch test dot php touch test dot css for example enter. So now i created three different files so now the remember that ls the one that lets us look inside.

Of the directory or inside of a folder lets go ahead and press ls press enter and as you could. See is showing me the three different files inside of that folder and here i could go ahead and go. To my finder double-click folder one and i should see three different files here created so i just cleared the. Page one more time so we start here from a blank slate but i want to show you how to. Delete one of the files that we created so again im still inside a folder one inside of my home.

There to rehear but i want to go ahead and delete this so the command for that is rm and. Then the name of the file so test dot php now before i press enter i gotta let you know. Theres no garbage can here so inside a terminal when you delete a file is gone theres no way to. Get it back so make sure you know what youre doing here before you do this inside a terminal let. Me press enter and as you can see right here ill find that that file just disappeared so again if.

I wanted to make it again touch test dot php enter and i could create it again obviously its easy. To create here because its just a blank document here but if i deleted the real thing it would have. Been a problem if i didnt mean to do it so now let me type in ls to look inside. And then all those three are back so again if i put rm test dot php delete it and then. Type in ls again to see the directory and the files inside of it you could see the one disappeared.

Im just keeping the finder window open here so you could see that visual representation of whats going on inside. Of the terminal so i just typed in cd again cd usually just brings you back to the root directory. Here so again its gonna bring me back to this home folder where i have all these folders here including. Folder one that are created thats just by typing cd anytime and then if i type in ls you could. See all the folders inside of that root directory again so next command we want to look a.

Conclusion – How To Access Terminal On Mac

The purpose of this post is to assist people who wish to learn more about the following – terminal commands mac tutorial – how to use terminal on mac, open mac terminal in specific directory or folder in mac, how to run any app using terminal on macos, how to open terminal macos cli ( monterey zsh ), how to use ssh on your mac with terminal, macos terminal (zsh) – the beginners’ guide, ssh with mac terminal, run, easily run python 3 code on terminal | mac os | 2019, how to open files with terminal on a mac, advanced macos tricks and utilities using terminal!, how to switch back to bash in terminal on macos catalina, mac terminal  10 awesome mac terminal commands!, secret mac boot commands – mac boot key combinations, how to prank friends by remotely accessing their computer using terminal on mac!.

Thank you for visiting Softwarediscover.com and reading this article! If you found this article useful, feel free to share it with your friends and help spread knowledge.