Host YD

Check promos before your Next order

How to Use Secure Shell: A Complete Beginner’s Guide 

So you need to log into a server and you keep hearing “just SSH into it.” Fine — but what does that actually mean?

SSH stands for Secure Shell. It’s a protocol. That’s it, nothing fancy. What it lets you do is connect to another computer over the internet and run commands on it like you were sitting right in front of it, except everything going back and forth is encrypted.

I’ve been using it for years and honestly most people overcomplicate the explanation. You type a command, you get a password prompt (or a key check), and then you’re basically inside the remote machine’s terminal. Files, processes, configs — all of it, accessible from wherever you happen to be.

Developers use it constantly. Sysadmins live in it. Hosting companies expect you to know it. If you’ve bought a VPS and had no idea what to do next, this is probably the piece you were missing.

What Secure Shell Actually Does?

SSH keeps your connection to a remote machine private. Before SSH existed, people used things like Telnet, which sent everything — passwords included — in plain text. Anyone snooping on the network could just read it. SSH fixed that by encrypting the whole session.

To use it you need two things on two different machines:

  • An SSH server running on the remote box (the one you’re connecting to).
  • An SSH client on your own computer (the one you’re connecting from).

Most Linux servers already run an SSH server by default. Your laptop almost certainly has a client built in already, whether you’re on Mac, Linux, or a reasonably modern Windows machine.

Before you even try connecting, get this info from whoever set up the server — your host, your IT team, yourself from six months ago if you forgot:

  • Server IP address or hostname.
  • Your username on that server.
  • A password, or a private key file.
  • The port SSH is listening on (usually 22, though plenty of admins move it elsewhere).

And obviously — only connect to machines you’re actually allowed to touch. Don’t be that person.

Which SSH Client Should You Use?

If you’re on Mac or Linux — don’t worry about it, you already have one. Open Terminal, type ssh, done.

Windows used to be the annoying one, but that’s not really true anymore. Windows 8.1 and up ships with OpenSSH built into the command line. There’s also PuTTY if you want something with a GUI, or Windows Terminal if you like things looking nicer. It doesn’t matter much which you pick, they all get you to the same place.

Password vs Key-Based Login

Two ways to prove it’s really you:

  • Password login is exactly what it sounds like — type your password, hit enter, hope you didn’t mistype it. Easy, but weaker. Passwords get guessed, phished, brute-forced.
  • Key-based login uses a matched pair of cryptographic keys instead. This is what actual professionals use, and once it’s set up, it’s honestly less hassle too — no typing a password every single time.

About Those Keys

A key pair has two halves. The private key stays on your machine, forever, never leaves. The public key gets copied onto the server. When you connect, the two get checked against each other and if they match — you’re in.

Commands You’ll Actually Use

Once inside, it’s standard Linux stuff:

pwd

Where am I right now?

ls

What’s in this folder?

cd folder-name

Move into that folder.

mkdir new-folder

Make a new one.

exit

Get out, close the session.

That’s genuinely 80% of daily usage right there.

Tweaking SSH Settings

There’s a config file that controls how SSH behaves — what auth methods it’ll accept, which port it listens on, whether root can log in directly (please turn this off), stuff like that.

If you’re the one managing the server, go carefully here. It’s shockingly easy to lock yourself out by messing with the wrong setting and not realizing until your next connection attempt just… fails.

Keep things updated. Limit who has access. Don’t leave password login on if you don’t need it. None of this is exciting advice but it’s the stuff that actually matters.

Running a VPS? You’ll Need This

If you’ve rented a VPS, SSH is basically the only door in. Nobody’s driving to a data center to plug in a keyboard. Your provider gives you an IP, a username, some credentials, maybe a custom port — and from there SSH is how you install software, tweak configs, move files, check what’s running, restart things when they break.

When It Just Won’t Connect

It happens to everyone. Usual suspects, roughly in order of likelihood:

  • You typo’d the IP or hostname (happens more than anyone admits)
  • Wrong username
  • Wrong password or the wrong key file
  • Server’s just down
  • A firewall’s blocking the port
  • Something in the config got changed and broke things

Recheck the basics first, before you assume it’s something exotic. Confirm the SSH service is actually running on the server. Check the port’s open. If none of that turns anything up, server logs usually point at the real problem pretty quickly.

Keeping It Secure

A short list, nothing revolutionary:

  • Guard your private key like it’s your house key, because functionally it is.
  • Patch your OS and SSH software when updates come out.
  • Only give access to people who genuinely need it.
  • Use keys instead of passwords wherever you reasonably can.
  • Watch for weird login attempts.
  • Never, ever post a private key publicly — this happens more than you’d expect on GitHub.

Bottom Line

SSH isn’t optional if you’re touching remote servers, it’s just the thing you use, daily, without really thinking about it after a while. Client on your end, server on the other end, valid credentials, right port. That’s the whole shape of it.

Get the basics down, layer on decent security habits, and you’ll be managing servers, VPSs, dev boxes, whatever, without much drama.