All Tools View Categories About Contact Privacy

Terraform Command Cheat Sheet

A quick reference of common terraform CLI commands.

Runs entirely in your browser - nothing is uploaded and no Terraform connection is made.
0
commands shown

About Terraform Command Cheat Sheet

The Terraform Command Cheat Sheet is a fast, filterable reference for the most common terraform CLI commands you reach for every day. Whether you are initializing a new working directory, planning and applying changes, importing existing infrastructure, inspecting state or managing workspaces, this cheat sheet keeps the exact invocation and its purpose one keystroke away.

Instead of hunting through documentation or guessing flags, you type a keyword such as plan, state, import or workspace and the list narrows to the matching commands and their short descriptions. Each entry explains what the command does and when to use it, so it doubles as a learning aid for newcomers and a memory aid for seasoned engineers.

The tool runs entirely in your browser. The command list is rendered locally, nothing is uploaded, and there is no connection to a Terraform binary or a remote API. You can copy the visible list to the clipboard, download it as a plain text file for offline use, or print it as a wall reference. Filtering supports partial matches, so a fragment like init matches terraform init while state surfaces every state subcommand.

The cheat sheet is also handy while assembling CI pipelines. A quick glance confirms the correct ordering of init, validate, plan and apply, and reminds you of flags like -out, -auto-approve and -var-file that are easy to mistype. Because the data is bundled with the page, the reference keeps working with no network access once it has loaded. Use it during pair programming, incident response, or as a teaching handout in workshops.

Features

  • Common commands - init, plan, apply, destroy, import, refresh, output, show and more.
  • State and workspace - state list, state rm, state mv, workspace new, workspace select and workspace list.
  • Lifecycle controls - taint, untaint, fmt and validate.
  • Instant filter - narrow the list by command name or description.
  • Partial matching - a fragment matches any part of a command or its note.
  • Case-insensitive - state and STATE both work.
  • Grouped reference - covers init, plan, apply, destroy, import, state, workspace, taint and formatting.
  • Command count - a live stat shows how many commands match.
  • Copy - send the visible list to the clipboard.
  • Download - save the list as terraform-cheat-sheet.txt.
  • Print - open a printer-friendly view.
  • Sample - load a preset filter to see it work.
  • No dependencies - pure browser rendering with no build step or server.
  • Private - everything runs locally, nothing leaves the browser.

How to Use

  1. Open the cheat sheet - the full command list renders on load.
  2. Type a keyword in the filter box, for example plan, state, import or workspace.
  3. Watch the list narrow to commands whose name or description contains your keyword.
  4. Clear the filter to show every command again.
  5. Load a sample filter preset to see realistic usage quickly.
  6. Combine filters - clear and retype to move between topics like destroy and refresh without leaving the page.
  7. Copy the visible list to the clipboard for pasting into notes or a runbook.
  8. Download the list as a text file for offline reference.
  9. Print a clean copy to pin near your desk or share in a workshop.
  10. Reuse across sessions - bookmark the page so the reference is always one tab away during incident response.

Examples

Example 1 - plan focus. Filter "plan" to see terraform plan and terraform plan -out=planfile with a short note on each.

Example 2 - state focus. Filter "state" to list terraform state list, terraform state rm and terraform state mv in one view.

Example 3 - import focus. Filter "import" to surface terraform import and its typical use when bringing existing resources under management.

Example 4 - workspace focus. Filter "workspace" to compare terraform workspace new, select and list before switching environments.

Example 5 - destroy focus. Filter "destroy" to compare terraform destroy with terraform destroy -target and terraform destroy -auto-approve before a teardown.

Benefits

  • Fast lookup - find the right command in seconds instead of searching docs.
  • Fewer mistakes - see exact flag spelling before you run it.
  • Confidence - verify command order before running in production.
  • Portable - copy, download or print the list anywhere.
  • Teaching aid - a calm reference for onboarding and workshops.
  • Privacy first - no upload and no Terraform connection.
  • Always available - works offline once the page is open.

Frequently Asked Questions

What is this?
A static, filterable cheat sheet of the most common Terraform CLI commands with short descriptions.
Which commands are listed?
init, plan, apply, destroy, import, output, refresh, show, providers, version, workspace, state, taint, untaint, fmt and validate.
Can I filter?
Yes. Type a keyword in the filter box to narrow the list by command or description.
Does this connect to Terraform?
No. The list is rendered in your browser and nothing is uploaded.
Can I copy it?
Yes. Copy the visible list, download it as a text file, or print it.