PowerShell Cheat Sheet

Searchable reference for everyday PowerShell cmdlets.

Open tool

Overview

A searchable reference for the PowerShell cmdlets you reach for daily - filesystem, process management, network, registry, text processing, and object pipeline manipulation. Filter by category or type any partial cmdlet name (Get-Ch, Select-).

It's for Windows developers and sysadmins moving between bash habits and PowerShell idioms, and for cross-platform users running PowerShell 7 on macOS or Linux. Reach for it when a teammate suggests a one-liner you've never seen, or when you'd rather not Get-Help your way through every cmdlet name.

How it works

The reference indexes the cmdlets in modern PowerShell (7.x) and the ones common to Windows PowerShell 5.1 where you'll be expected to know them. Each entry shows the verb-noun name, a one-line description, and a representative example. Aliases (ls, cd, cat) are listed against their canonical cmdlet so you can spot the Unix-shell shortcut.

Categories follow PowerShell's conceptual model - object pipeline, providers, modules - rather than the docs' alphabetical reference layout. The data is informational, drawn from Microsoft's PowerShell documentation.

Examples

  • File ops:
    Get-ChildItem -Path . -Recurse -Filter *.log
    Remove-Item -Path .\old\ -Recurse -Force
    
  • Filtering pipeline output:
    Get-Process | Where-Object CPU -gt 100 | Select-Object Name, CPU
    
  • Network:
    Test-NetConnection -ComputerName example.com -Port 443
    Invoke-RestMethod -Uri https://api.example.com/data
    
  • Splatting cmdlet parameters:
    $params = @{ Path = '.'; Recurse = $true; Filter = '*.txt' }
    Get-ChildItem @params
    

FAQ

Windows PowerShell 5.1 vs PowerShell 7?

5.1 is Windows-only and frozen. 7.x is the active cross-platform line. Most cmdlets work in both, but PS7 adds &&, ||, ternary, and ?? operators absent from 5.1.

Why do cmdlets use Verb-Noun?

It's a deliberate convention - it makes discovery easier (Get-Command Get-*) and lets parameters and behaviours stay consistent across modules. Approved verbs are listed in Get-Verb.

How do I make my scripts cross-platform?

Target PS 7+, avoid Windows-specific cmdlets (Get-WmiObject, New-PSDrive with HKLM), use Path.Combine-style joins via Join-Path, and check $IsWindows / $IsLinux for platform branches.

Is the cheat sheet exhaustive?

No - it covers the daily essentials. For a full inventory use Get-Command or browse the PowerShell module docs.

Try PowerShell Cheat Sheet

An unhandled error has occurred. Reload ×