Tools

SSH Cheat Sheet

Print-ready cheat sheet for SSH, organized for fast lookup, study, and desk-side use

Source
OpenSSH Documentation (openssh.com)
License
MIT
Updated
2026-03-27

Sample

What's in this cheat sheet

  • Connecting
  • Key Management
  • Config File
  • Port Forwarding
  • SCP & SFTP
  • Agent Forwarding
  • Tunnels
  • Troubleshooting
  • Security Best Practices
  • Multiplexing
  • Escape Sequences

Basic Connection

ssh user@host                   # connect to host
ssh -p 2222 user@host           # custom port
ssh user@host command            # run remote command
ssh -t user@host "top"          # force TTY allocation

Connection Flags

-p portConnect to specific port
-i keyUse specific identity (private key)
-tForce pseudo-terminal allocation
-v / -vv / -vvvVerbose debugging (increasing detail)
-qQuiet mode (suppress warnings)
-NNo remote command (for tunnels)
-fGo to background before command
-J jumpJump host (ProxyJump)

Download the full cheat sheet for all sections, formatted for print

Download PDF

Downloads

Choose the treatment that matches how you read