Skip to content

Yazi - Blazing Fast Terminal File Manager Cheatsheet

Yazi - Blazing Fast Terminal File Manager Cheatsheet

Section titled “Yazi - Blazing Fast Terminal File Manager Cheatsheet”

A blazing fast terminal file manager written in Rust, built on async I/O. Features image previews, bulk operations, Vim-like keybindings, a Lua plugin system, and integrations with ripgrep, fd, fzf, and zoxide.

PlatformCommand
macOS (Homebrew)brew install yazi ffmpegthumbnailer poppler fd ripgrep fzf zoxide font-symbols-only-nerd-font
Arch Linuxsudo pacman -S yazi ffmpegthumbnailer poppler fd ripgrep fzf zoxide
Ubuntu/DebianDownload from GitHub releases
Fedora/RHELsudo dnf install yazi
Windows (Scoop)scoop install yazi
Windows (Winget)winget install sxyazi.yazi
Cargo (All platforms)cargo install --locked yazi-fm yazi-cli
Nixnix-env -iA nixpkgs.yazi

Optional dependencies for full features: ffmpegthumbnailer (video thumbnails), poppler (PDF preview), fd, ripgrep, fzf, zoxide, ImageMagick, 7-Zip/unar.

Launch: Run yazi or yazi /path/to/dir

KeyDescription
hGo to parent directory
l or EnterOpen file or enter directory
jMove cursor down
kMove cursor up
JMove cursor down 5 lines
KMove cursor up 5 lines
g gJump to first item
GJump to last item
HGo back in history
LGo forward in history
~Go to home directory
BackspaceGo to parent directory
zJump via zoxide (fuzzy directory search)
ZJump via fzf
KeyDescription
oOpen selected file with default program
OOpen file interactively (choose program)
yYank (copy) selected files
xCut selected files
pPaste yanked/cut files
PPaste with overwrite
dTrash selected files
DPermanently delete selected files
aCreate a new file or directory (append / for directory)
rRename selected file
cRename with cursor at start
.Toggle showing hidden files
KeyDescription
SpaceToggle selection on current item
vEnter visual mode (select range)
VEnter visual mode (unselect range)
Ctrl+aSelect all items
Ctrl+rInverse selection (toggle all)
EscCancel selection / exit visual mode
KeyDescription
/Search in current directory
?Search backwards
nJump to next search match
NJump to previous search match
fFilter current directory (show matching only)
sSearch files with fd across subdirectories
SSearch file contents with ripgrep
KeyDescription
,mSort by modified time
,MSort by modified time (reverse)
,cSort by created time
,CSort by created time (reverse)
,eSort by extension
,ESort by extension (reverse)
,aSort alphabetically
,ASort alphabetically (reverse)
,nSort naturally (number-aware)
,NSort naturally (reverse)
,sSort by size
,SSort by size (reverse)
,rSort randomly
KeyDescription
tCreate new tab
1-9Switch to tab by number
[Switch to previous tab
]Switch to next tab
{Swap tab with previous
}Swap tab with next
KeyDescription
Space (on multiple)Select multiple files, then use y/x/d
rRename (use on selection for bulk rename)
  1. Select files with Space or visual mode (v)
  2. Press r to open bulk rename in your $EDITOR
  3. Edit filenames in the editor
  4. Save and close — Yazi applies all renames

Yazi provides built-in previews for many file types:

File TypePreview
Images (PNG, JPG, etc.)Inline image preview (in supported terminals)
VideosThumbnail preview (requires ffmpegthumbnailer)
PDFsFirst page preview (requires poppler)
Text/CodeSyntax-highlighted preview
ArchivesContents listing
DirectoriesChild file listing

Supported terminals for image preview: Kitty, iTerm2, WezTerm, Ghostty, foot, Konsole, Windows Terminal, VSCode, Warp.

FilePurpose
~/.config/yazi/yazi.tomlGeneral settings
~/.config/yazi/keymap.tomlCustom keybindings
~/.config/yazi/theme.tomlColors and styles
~/.config/yazi/init.luaPlugin initialization
[manager]
show_hidden = false          # Show dotfiles by default
sort_by = "natural"          # natural, alphabetical, size, modified, created, extension
sort_dir_first = true        # Directories before files
linemode = "size"            # Info shown next to filename: size, mtime, permissions, none

[preview]
max_width = 1000             # Max preview width
max_height = 1000            # Max preview height
image_quality = 75           # JPEG quality for thumbnails

[opener]
# Custom file openers
edit = [{ run = 'nvim "$@"', block = true }]
open = [{ run = 'open "$@"' }]  # macOS: open, Linux: xdg-open

Add to your shell config so exiting Yazi puts you in the last directory you visited:

Bash/Zsh:

function y() {
  local tmp="$(mktemp -t "yazi-cwd.XXXXXX")" cwd
  yazi "$@" --cwd-file="$tmp"
  if cwd="$(command cat -- "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
    builtin cd -- "$cwd"
  fi
  rm -f -- "$tmp"
}

Fish:

function y
  set tmp (mktemp -t "yazi-cwd.XXXXXX")
  yazi $argv --cwd-file="$tmp"
  if set cwd (command cat -- $tmp); and [ -n "$cwd" ]; and [ "$cwd" != "$PWD" ]
    builtin cd -- "$cwd"
  end
  rm -f -- $tmp
end
# Install a plugin
ya pack -a owner/plugin-name

# Update all plugins
ya pack -u

# List installed plugins
ya pack -l

Popular plugins: git status integration, archive extraction, image manipulation, custom previewers.

# Launch in a specific directory
yazi ~/projects

# Quick file browsing with image previews
yazi ~/photos

# Bulk rename workflow
# 1. Navigate to directory
# 2. Select files with Space or v
# 3. Press r to bulk rename in editor
FeatureYazirangerlfnnn
LanguageRustPythonGoC
Async I/OYesNoNoNo
Image previewNativeYesPluginPlugin
Plugin systemLuaPythonShellShell
SpeedVery fastModerateFastVery fast
Bulk renameBuilt-inBuilt-inExternalExternal
Vim keybindingsYesYesYesNo