zoxide: a tiny tool that will noticeably speed up your terminal work
If you spend a lot of time in the terminal, you're probably constantly jumping between projects, repositories and various directories. That's exactly where zoxide shines. This unassuming tool, which replaces the classic cd, can make your everyday work noticeably more pleasant — and after a few days of use, the terminal starts to feel pointlessly slow without it.
If you spend a lot of time in the terminal, you’re probably constantly jumping between projects, repositories and various directories. That’s exactly where zoxide shines. This unassuming tool, which replaces the classic cd, can make your everyday work noticeably more pleasant — and after a few days of use, the terminal starts to feel pointlessly slow without it.
What is zoxide
zoxide is a smart replacement for the classic cd command. It remembers which folders you visit most often and uses that to let you move around your system faster.
Instead of typing out long paths or endlessly hitting tab, it’s often enough to type just part of a project or directory name. zoxide gradually builds its own database of paths you use and starts guessing where you want to go.
It’s not a revolutionary concept. It’s more about removing a small everyday annoyance that most people in the terminal don’t even consciously notice.
What it looks like in practice
Basic usage is simple. Instead of cd ~/Dropbox/workspace/project you type:
z project
If the name isn’t unambiguous, you can narrow it down with multiple terms:
z foo bar # a folder containing both "foo" and "bar"
z .. # one level up (like cd ..)
z - # back to the previous folder
The z command works as a drop-in replacement for cd — it just adds smart guessing of the destination based on history.
The terminal starts to feel smarter
The biggest difference isn’t that you save a few keystrokes when typing. What matters more is the change in your overall workflow.
After a while, you stop thinking about the exact directory structure. All you need to remember is:
- the project name,
- part of the folder name,
- or just a few characteristic letters.
This significantly speeds up switching between projects, working in larger repositories, returning to unfinished work, and finding your way around dotfiles or monorepos.
The longer you use zoxide, the more useful it becomes. Every time you move into a directory, it stores information about how often and when you visited that folder, and builds its own priority database from this data. It stores this locally on disk and gradually adjusts it based on your real habits. So when you type just part of a directory name, zoxide doesn’t just look for an exact match — it tries to guess the most likely destination based on a combination of the name, frequency of use and last visit.
You’ll notice the biggest benefit in everyday work
zoxide isn’t a tool that wows you in the first five minutes. Its strength shows after a few days of regular use.
A typical situation: you open the terminal in the morning, move between several projects throughout the day, occasionally jump into your editor’s config, then into a repository, then back to the backend or frontend part of the application. That’s exactly where the classic cd becomes surprisingly uncomfortable. zoxide removes most of the unnecessary typing from these small operations.
Even stronger combined with fzf
fzf is a popular fuzzy finder for the terminal, and it forms a very strong combination with zoxide.
And if you want an interactive selection through fzf:
zi foo # shows a filtered list and lets you pick
Interactive directory selection using fuzzy search feels significantly more modern than classic shell navigation. Once you get used to quickly finding projects and folders with just a few characters, going back tends to be surprisingly unpleasant.
It’s exactly the combination of zoxide, fzf, a modern shell and, say, tmux or Neovim that can make a developer’s everyday work noticeably more pleasant.
It’s not an essential tool. And that’s exactly why it’s so good
zoxide doesn’t solve a big problem. It won’t speed up your builds or replace your editor. It just removes a small amount of friction that keeps repeating throughout the day.
And it’s exactly tools like this that often have the biggest impact on your comfort at work. After a few weeks of use, you realize that a terminal without zoxide feels strangely slow and clunky.
Links
- Homepage: zoxide.org
- GitHub: github.com/ajeetdsouza/zoxide
- fzf: github.com/junegunn/fzf