Shell Command Explainer
Decode flags, pipes and redirections offline — with destructive-command warnings.
A POSIX-aware tokenizer splits quotes, escapes, pipelines, chains and redirections into command units, then an offline dictionary of common tools explains each flag and argument. Combined short flags are split, --flag=value forms are bound, and unknown commands or flags are labelled honestly rather than guessed. Rule-based warnings flag destructive shapes such as rm -rf, dd writing to a device, piping into a shell, git force operations and elevated privileges. The command is never executed and never leaves the browser tab.
Command
Offline dictionary v2026.11 · 33 commands. Nothing is executed or uploaded.
Explanation
0 command unit(s)No command to explain
Paste a command or load an example above.
Examples
Log search pipeline
cat app.log | grep -i errorUnit 1: cat app.log · Unit 2 (after |): grep -i error-i is explained as case-insensitive matching and the pipe as feeding output into the next command.
Combined short flags
ls -la /var/log-l: long format · -a: include hidden files · /var/log: path operandThe tokenizer splits -la into two known flags while preserving the original command text.
Destructive command
rm -rf /tmp/oldHigh severity warning: recursive or forced removalThe risk rules surface the consequence before the command is run elsewhere.
About this tool
Shell Command Explainer decodes a pasted command token by token without executing it. A POSIX-aware tokenizer keeps quoted strings together, recognises escapes, variables and globs, and splits pipelines, chains and redirections into numbered command units.
Each unit is looked up in a versioned offline dictionary of common tools — git, docker, kubectl, tar, grep, sed, awk, find, curl, ssh, rsync, chmod, dd, npm and more. Combined short flags such as -la are split into individual explanations, --flag=value forms are bound, and value-taking flags show which word supplies their value. Unknown commands and flags are labelled as unknown rather than guessed.
A separate rule set warns about destructive shapes: recursive or forced removal, raw device writes, world-writable recursive chmod, piping a download into a shell, forced Git operations, SIGKILL and elevated privileges. Everything runs in the browser; the command is never executed or uploaded.
What this tool does not do
- The dictionary covers common tools and flags, not every utility or version-specific option.
- Explanations are static; shell functions, aliases and environment-specific wrappers are not resolved.
- The tokenizer handles common POSIX syntax but is not a full shell parser for every bash extension.
- Commands are never executed, so behavioural details that depend on the system cannot be verified.
How to use this tool
Paste a command
Type or paste one or more shell lines into the editor, or load an example chip.
Read the command units
Pipelines and && / ; chains are split into numbered units with their connecting operator shown.
Inspect tokens
The token-by-token list explains the program, each flag, flag values, variables, globs and operands.
Review safety warnings
Destructive patterns appear in a separate panel with a plain-language consequence.
Copy the breakdown
Copy a Markdown summary for a ticket, code review or team hand-off.
Use cases
Review an unfamiliar command
Decode a snippet from a forum or incident ticket before running it.
Safety review
Spot destructive flags in a deployment script or copied one-liner.
Teaching shell syntax
Show learners what each token, pipe and redirection does in plain language.
Token roles
| Role | Meaning |
|---|---|
| Command | Program name looked up in the offline dictionary. |
| Flag | Known option with its plain-language meaning; combined short flags are split. |
| Flag value | The word bound to a value-taking option such as -o or --output. |
| Expansion | $VAR and ${…} markers, annotated but never resolved. |
| Operator | |, &&, ||, ; and & connecting command units. |
Unknown commands and flags keep their original token text and receive an explicit honesty badge.
Common mistakes
Mistake:Piping an unverified download into sh or bash.
Fix:Download, read and then execute; the tool flags this pattern as high severity.
Mistake:Assuming an unknown flag is harmless.
Fix:The explainer marks it as unknown; check the tool's own help before running.
Mistake:Forgetting that $VAR is expanded by the shell.
Fix:Variables are annotated but never resolved here, so review the actual value yourself.
Mistake:Running rm -rf with a variable path without expanding it.
Fix:Print the expanded path first; a typo with a leading slash can remove far more than intended.
Frequently asked questions
How does it know what flags mean?
From a versioned, offline dictionary of common commands and their options. Combined short flags such as -la are split into -l and -a, and --flag=value forms are handled as a flag plus a value. If a command or flag is not in the dictionary, the tool says so instead of guessing.
Does it execute my command?
No. The command is tokenised and compared against rules in your browser tab. It is never executed, sent to a server or stored.
Which shells and syntax does it parse?
It targets POSIX shell syntax: single and double quotes, backslash escapes, variables, globs, pipelines, &&, ||, ;, background &, and common redirections including >> and 2>&1. Bash-specific extensions such as process substitution are treated as generic tokens.
Can it explain pipes and redirections?
Yes. Pipes and chain operators split the command into numbered units with an explanation of the connection. Redirections are tokenised separately so you can see where output and errors go.
What tools are covered?
Around two dozen everyday utilities, including ls, cp, mv, rm, grep, sed, awk, find, tar, curl, ssh, rsync, chmod, chown, kill, dd, git, docker, kubectl, npm, pnpm, sudo and more. The dictionary version and command count are shown in the tool.
Does it warn about dangerous commands?
Yes. Rules flag recursive or forced removal, writing to device files, world-writable recursive chmod, piping a download into a shell, hard resets and force pushes, SIGKILL, sudo and redirection into device files. Warnings are informational; always verify the command yourself.
References & standards
Related tools
.env Secret Safety Linter
Validate .env syntax and spot likely leaked credentials or placeholder secrets.
.gitattributes Generator
Build .gitattributes rules for line endings, Git LFS, GitHub linguist marks and merge drivers — with a one-line explanation for every rule.
.htaccess Generator
Build an Apache .htaccess — HTTPS redirects, rewrites, error pages, security headers, and basic auth
2D Fluid Dynamics & Particle Physics Sandbox
A physics playground with two engines sharing one canvas. The fluid mode runs a real Eulerian Navier-Stokes solver — semi-Lagrangian advection, explicit diffusion, Jacobi pressure projection and vorticity confinement — that you paint with dye and velocity using mouse or touch. The particle mode is a damped Verlet N-body engine with gravity wells, Coulomb attractors and repulsors, spring links, wall restitution and elastic circle collisions. Particle counts adapt to the device (100k target on WebGL2 desktop, 2k-5k on CPU fallback), and every configuration exports as runnable code: a Matter.js world, a PixiJS ticker setup, or a standalone vanilla Canvas engine.
A/B Test Sample Size Calculator
Compute required sample size per variant and test duration from baseline conversion rate, minimum detectable effect, alpha and power.
ABA Routing Number Validator
Validate 9-digit US ABA routing numbers with 3-7-1 Mod-10 breakdown.