An illustrative photo of a computer terminal with green and blue text
Tutorials |

A beginner's guide to the terminal

Julia.png

Julia

October 14, 2025

tl;dr quick summary
We've all seen that black screen with green text that hackers use in movies. What if I told you it's a real thing on your computer right now? It's called the Terminal, and even though it won't let you break into government databases (please don't try), it can help you navigate files faster, automate boring tasks, and generally make you feel like you know what you're doing with computers. This isn't a guide for professional developers, it's for curious beginners who've always wondered "What even is that Terminal thing, and why should I ever open it?" If you've never typed a command in your life, you're in exactly the right place.

That stuff you see hackers do in movies? You can do (some of) it too!

We’ve all seen the setting: a shadowy figure in a black hoodie stares intensely at a black screen filled with green text that rushes past, typing furiously. A few seconds later: bam! They’re inside the CIA’s internal network.

Butterfly meme where the butterfly is a terminal window and the person says "Is this hacking?"

While this is wildly exaggerated (and entertaining), there is a real version of that mysterious window on your computer and it’s called the Terminal. It might not let you hack into government agencies (please don’t try), but it will let you do some surprisingly useful things: like navigating your files more quickly, automating boring tasks, or just feeling a little bit more like you actually know your computer.

This guide isn’t for professional developers. It’s for curious beginners, non-devs, or anyone who’s ever asked:

What even is that Terminal thing - and why should I ever open it?

If you’ve never used the terminal before, you’re in the right place. We’ll walk through what it is, how to open it, and how to do a few cool things in it - even if you’ve never written a line of code.

📍 Note for readers: This guide focuses on macOS and the built-in Terminal app. While the core concepts apply to all operating systems, the specific commands and screenshots were made on a Mac. Linux users will find that most commands are identical while Windows users might have to look up how commands are worded differently on their system.

What even is the terminal?

Most people interact with their computer using graphical tools - clicking folders, dragging files, opening apps. This is called a graphical user interface (GUI), and it’s what we’re all used to: navigating files works via Finder on a Mac and File Explorer on Windows (and if you're using some Linux distribution, you'll know exactly what your explorer is called 😉).

A Finder window in MacOS

A Finder window in MacOS

The Terminal, on the other hand, is a way to interact with your computer using text only. It may look weird at first as it's just a blinking cursor in a black window - but it gives you precise control over your system.

The Terminal in MacOS showing the result of the echo Hello World command: the output is Hello World

The Terminal in MacOS

A bit of history

Before graphical interfaces existed, all computers were controlled through a terminal. Users typed instructions, and the computer responded with output. That same power still exists today, though it's hidden behind the visual interfaces we're used to.

The Terminal gives you access to that older but still very powerful way of interacting with your machine. Many developers and power users still rely on it every day to move through files, install tools, or automate repetitive tasks.

So what can you actually do with it?

With the Terminal, you can:

  • 📂 View your folders and navigate through them
  • 📝 Create, rename, edit or delete files
  • ⬇️ Install and run software tools
  • 🔁 Automate repetitive steps with scripts
  • ⚙️ Access system-level settings and utilities

In many cases, the Terminal can be faster than clicking through menus, especially for small tasks that you repeat often.

How to open the Terminal on macOS

The Terminal is built into every Mac. You don’t need to install anything - just open it like any other app:

  • Via Spotlight Search: Press Cmd + Space, type Terminal, and hit Return.
  • Via Finder: Go to ApplicationsUtilitiesTerminal.
  • Pin it to your Dock if you plan to use it regularly.

Once it opens, you’ll see a prompt that looks similar to this:

This line shows your username and the device name, the current folder you’re in (~ stands for your home folder), and ends with the percent symbol (%) which means the Terminal is waiting for your input. This is where you’ll type your first commands. Mind that the prompt can be configured, so don't be surprised if yours looks different from this example or the one on your programmer friend's system.

Let's try it out!

📝 Logging information

Let’s start with something simple: have the Terminal print a message back to you. There’s a command called echo that does just that: It takes a string of text and displays it in the Terminal window. Think of it as a way to ask the computer to repeat something back to you - like a digital "say this out loud”.

Here’s how it works:

When you type that and press Return, you should see something like this:

That’s it, you’ve just run your first terminal command! Feel free to try again and change the message to anything you'd like.

💡 What’s happening here?

  • echo is the command
  • "Hello, world!" is the argument you're giving it: in this case, a short message in quotation marks
  • The Terminal takes that input and prints it directly to the screen

Maybe you've heard of similar functions in programming languages, e.g. console.log() in JavaScript or a basic print() statement in others. Developers often use echo to display messages, confirm that a script is running, or quickly check that everything is working as expected.

Navigating Files in the Terminal

Once you're comfortable printing a line with echo, the next step is learning how to move around inside your computer's folders without using Finder.

In the Terminal, you do this by typing commands instead of clicking. It might feel unfamiliar at first, but with just a few simple tools, you’ll be able to check where you are, see what's around you, and move from folder to folder - all from the keyboard.

📌 Where am I?

Let’s start by figuring out where you are.

This stands for "print working directory”, which is a technical way of saying "show me my current folder.” Try it out! You should see something like this:

That’s your home directory - your personal space on the computer. Think of it like the front door of your apartment.

📂 What’s in this folder?

To see what’s in the folder you’re currently in, use ls. This stands for list, and it will show all files and folders at your current location.

Try it out! You might see folders like Documents, Downloads, or Desktop:

Want more detail? Add some flags to modify the output. For example -l: This gives you extra information like file sizes and dates.

Add -a (or directly combine it with -l by using -la) to also show hidden files:

Think of ls like opening a drawer to see what's inside. Flags like -l and -a are like choosing to open it with a flashlight 🔦 or magnifying glass 🔍.

🚶 Go somewhere else

To move into a folder, use the change directory (cd) command. cd is like walking from room to room. You can tell your computer "Take me to the Documents room", for example.

For instance, to go into your Documents folder you'd enter:

Want to go back up one level again? Use two dots ... The .. means "the folder above this one” or in other words, the parent directory.

You can always find your way home to Users/my-username with the help of the tilde ~:

Alternatively, just typing cd will lead you to your home directory as well.

Creating and deleting files and folders

📁 Create a new folder

Want to make a new folder? Use the make directory command mkdir:

The name can be anything - just avoid spaces (use dashes or underscores instead). Now if you do ls afterwards, you should see your new folder somewhere in the list.

📝 Create a new file

To create a blank file, use touch:

This doesn’t open the file, it just creates it, like putting a blank sheet of paper on your desk. Mind that you have to add the file type, so, in this case, .txt, yourself. Try it out and you should see hello.txt appear (🤫 use the list command ls to check!). It’s empty for now, but it’s ready for you to edit later in a text editor or within the Terminal.

🗑️ Delete something

To delete a file, use the remove command rm ⚠️ but be careful! This won’t send it to the trash, it’s gone immediately. rm is like tossing a file straight into a paper shredder, no undo button.

To delete a folder and everything inside it do the following:

  • -r means "recursive" or, in other words, "everything inside, too”
  • add -f (force), so rm -rf folder-name, to skip warnings such as file permission issues. ⚠️ DANGER ZONE ⚠️ Do this only if you're absolutely sure!

Tips and tricks

Before we finish this little tutorial, here are some tips and tricks for you.

🤬 Oh no, I want to abort some running process / I entered something wrong but don't want to delete every character!

Don't fret: Just hit Ctrl + C on your keyboard - this will abort the current command and you can enter a fresh one. If that doesn't work, just close the whole terminal.

🤔 Why can't I just click somewhere in the text I just entered into the terminal to change something?

Editing the text by clicking into it isn't possible in the terminal. Instead, do this: select the text, copy it, and paste it into a text editor (Notes, TextEdit or something similar). There, you can make changes to the text and copy the result. Then, go back to the terminal (abort the current command if necessary like described above) and paste your new command.

😬 I want to cd into a folder with a very long name. Do I really have to enter the whole name?

No! You can use the autocompletion feature via the Tab key. Just start entering your file or folder name (e.g. cd Doc) and press Tab. If there are multiple folders starting with these characters, they will be shown to you. In that case, enter more characters until it's clear what folder you mean. Then press Tab again and the name will be completed! In case the command accepts a file, Tab works here as well.

🔙 I want to return to the folder I was at previously!

You can use cd - or even just - similar to the back button in a browser. Imagine you navigated to /some/path and then to /another/path. But then you have something to do at /some/path again! Instead of writing out the whole path again (cd /some/path), write - or cd - to return there.

There was this really nifty command I used before, but I can't remember what it was / how to write it...

You can have a look at your command history by typing history. This will by default show quite a lot of commands. If you don't need so many, just type history | tail to show the ten latest commands. You can also add a minus and a number at the end to query a specific number of commands, e.g. history | tail -20, to show the last twenty commands.

⁉️ Where did I install this again?

Sometimes you might wonder where a command actually lives on your computer (yes, commands are just executables - small programs that run on your computer). The which command shows you the exact file path of any command you type. This is particularly helpful when you have multiple versions of the same program installed. which will tell you which one your terminal is actually using.

For example, if you type which git (git is a popular version control system), it might show /usr/bin/git, revealing that when you run git, your computer is executing the program located at that specific path.

🎉 You did it!

You just learned the terminal basics - navigating folders, creating files, and using real developer commands. It might feel weird typing instead of clicking, but that's normal. Even knowing these few commands puts you ahead of most computer users. You can of course always switch between the Finder and the terminal.

Next time you see movie hackers at work, you know the truth: they're probably just navigating files really fast ⚡. And now you can too, minus the dramatic music.

Keep going: Try using the terminal once a week for small tasks. If you're up for more challenges, try to install something: A great starting point for this is Homebrew. You can picture Homebrew like an app store for the terminal. With its help, you can install a wide range of apps and commands, from well-known ones like Spotify to actual developer tools like git via your terminal. Happy exploring!

Cheatsheet

🤖 Statement on the use of AI in this article: This blogpost was written by humans (thanks for the feedback Lisa and Irena!), including the title, concepts, and code examples. However, we used AI for research and to improve the writing style.

Photo of the terminal by Pixabay on Pexels

Terminal

Guide

Beginner

Development

Read also

Lisa, 06/30/2025

“How sustainable is my company?” A first look at the B Impact Assessment

Corporate Social Responsibility

B Corp Zertifizierung

B Impact Assessment

Nachhaliges Wirtschaften

Impact Tools

Go to Blogarticle

Michael, 06/12/2025

Vibe Coding: Convert Excel apps to web apps. No code required.

Go to Blogarticle

Michael, 04/16/2025

Green Hosting: A Sustainability Comparison

Sustainability

Green Software

Consulting

Hostingsec

Go to Blogarticle