In your .zshrc you have the following two lines:

plugins=(z zsh-autosuggestions)
plugins=(zsh-autosuggestions)

The second line remove the z plugin. You should have only one line with:

plugins=(z zsh-autosuggestions)

According to the ZSH-z plugin Github homepage:

ZSH-z is a command line tool that allows you to jump quickly to directories that you have visited frequently in the past, or recently -- but most often a combination of the two (a concept known as "frecency"). It works by keeping track of when you go to directories and how much time you spend in them. It is then in the position to guess where you want to go when you type a partial string, e.g. z src might take you to ~/src/zsh.

Answer from Ortomala Lokni on Stack Overflow
🌐
GitHub
github.com › ohmyzsh › ohmyzsh › tree › master › plugins › z
oh-my-zsh/z
This plugin defines the z command that tracks your most visited directories and allows you to access them with very few keystrokes. Assume that you have previously visited directory ~/.oh-my-zsh/plugins.
Author   ohmyzsh
🌐
GitHub
github.com › ohmyzsh › ohmyzsh › blob › master › plugins › z › README.md
ohmyzsh/plugins/z/README.md at master · ohmyzsh/ohmyzsh
This plugin defines the z command that tracks your most visited directories and allows you to access them with very few keystrokes. Assume that you have previously visited directory ~/.oh-my-zsh/plugins.
Author   ohmyzsh
Discussions

Why plugin z of zsh is not active inside the .zshrc? - Stack Overflow
I installed oh my zsh and zsh auto suggestion. Then I read here (https://www.sitepoint.com/zsh-tips-tricks/) about z zsh, an interesting plugin. And I really wanted to install it. So I put the plugin More on stackoverflow.com
🌐 stackoverflow.com
PSA: Bug in Z plugin from oh-my-zsh
This project lives at https://github.com/rupa/z . Oh My Zsh has a copy of the upstream code. So you need to send a PR to rupa/z and then update Oh My Zsh once the PR is merged. More on reddit.com
🌐 r/zsh
4
6
September 18, 2020
My favorite Oh My Zsh plugins
autocompletion and syntax highlighting are also a must More on reddit.com
🌐 r/linux4noobs
24
77
April 8, 2022
What is the best plugin manager in your opinion?
Best plug-in manager is no plug-in manager. More on reddit.com
🌐 r/zsh
43
31
July 5, 2022
🌐
Oh My Zsh!
ohmyz.sh
Oh My Zsh - a delightful & open source framework for Zsh
Oh My Zsh is a popular open-source Zsh configuration framework loved by developers worldwide. It includes 300+ plugins, themes, and tweaks to supercharge your terminal experience.
🌐
GitHub
github.com › agkozak › zsh-z
GitHub - agkozak/zsh-z: Jump quickly to directories that you have visited "frecently." A native Zsh port of z.sh with added features. · GitHub
For tab completion to work, _zshz ... as zsh-z.plugin.zsh, and you will want to have loaded compinit. The frameworks handle this themselves. If you are not using a framework, put ... to your .zshrc, your completion menus will look very nice. This zstyle invocation should work with any of the frameworks below as well. ... Zsh-z is now included as part of Oh My ...
Starred by 2.4K users
Forked by 79 users
Languages   Shell
🌐
GitHub
github.com › ohmyzsh › ohmyzsh › wiki › plugins
Plugins · ohmyzsh/ohmyzsh Wiki
profiles: this plugin allows you to create separate configuration files for zsh based on your long hostname (including the domain). pulumi: this is an Oh My Zsh plugin for the Pulumi CLI, an Infrastructure as Code (IaC) tool for building, deploying and managing cloud infrastucture.
Author   ohmyzsh
🌐
Medium
senoritadeveloper.medium.com › mastering-zsh-on-macos-a-guide-to-oh-my-zsh-plugins-themes-and-productivity-hacks-00064e687a6f
Mastering Zsh on macOS: A Guide to Oh My Zsh, Plugins, Themes, and Productivity Hacks | by Nil Seri | Medium
March 1, 2025 - Oh My Zsh is a framework built on top of zsh that is structured to allow it to have plugins and themes. ... To enable the plugin, you need to add it to the config file (~/.zshrc).
Find elsewhere
🌐
GitHub
github.com › ohmyzsh › ohmyzsh › blob › master › plugins › z › MANUAL.md
ohmyzsh/plugins/z/MANUAL.md at master · ohmyzsh/ohmyzsh
As long as you are using an up-to-date installation of Oh My Zsh, you can activate Zsh-z simply by adding z to your plugins array in your .zshrc, e.g.,
Author   ohmyzsh
🌐
Alldrops
alldrops.info › posts › cli-drops › 2021-07-26_customize-zsh-part-4
Customize Zsh Pt.4 - ZSH-z Plugin – all drops
July 26, 2021 - This is a four-part post series explaining how to set up those features on a fresh new Zsh installation: ... ZSH-z is a command line tool that allows you to jump quickly to directories that you have visited frequently in the past, or recently…[read more] You may know that you could be using ...
🌐
Catalin's Tech
catalins.tech › zsh-plugins
The Only 6 Zsh Plugins You Need
February 24, 2026 - If you want to take your Mac terminal to the next level, check out iTerm2 + Oh-My-Zsh: Supercharge Your Mac Terminal. ... If you want to install all of these automatically on a new machine, including a Brewfile that handles the whole process, check out how I set up new MacBooks. The first plugin is git, which comes pre-installed with oh-my-zsh.
🌐
Mindthevirt
mindthevirt.com › home › 2023 – oh my zsh plugins: the best way to enhance your z shell
2023 - Oh My Zsh Plugins: The Best Way to Enhance Your Z Shell
August 20, 2023 - ZSH, or Z shell, is a powerful Unix shell that is used by many developers and power users. It offers a number of features that make it a great choice for those who want a more customizable and powerful shell, such as a powerful syntax highlighter, a comprehensive set of built-in commands and functions, and a wide range of plugins that can be used to extend its functionality. One of the best ways to enhance your Z shell experience is to use oh my zsh, a community-driven framework that makes it easy to manage your ZSH configuration.
🌐
Medevel
medevel.com › zsh-z-app
Zsh-z: Quickly Jump to Your Most Frequent Directory (Linux and macOS) - Supercharge Your Terminal
September 26, 2025 - Pure Zsh, No External Dependencies: Unlike rupa/z, which relies on awk, sed, sort, and other tools, Zsh-z uses only Zsh built-ins. This means faster performance, especially on Windows subsystems like WSL, Cygwin, and MSYS2, where it’s often over 100% faster. Rock-Solid Stability: A custom file-locking mechanism prevents race conditions and database corruption, a common pain point in rupa/z. Developer-Friendly: Lightweight, open-source, and easy to install via Oh My Zsh, Zinit, or manually.
🌐
SitePoint
sitepoint.com › blog › computing › 10 zsh tips & tricks: configuration, customization & usage
10 Zsh Tips & Tricks: Configuration, Customization & Usage — SitePoint
November 15, 2024 - Autosuggestions Plugin: Boost your efficiency with the autosuggestions plugin, which proposes commands as you type, based on your history, allowing for quicker command line operations. Navigational Shortcuts: Enhance directory navigation within Oh My Zsh by utilizing shortcuts like typing directory names directly or using the ‘z’ plugin to jump to frequently and recently used directories.
🌐
Linux Handbook
linuxhandbook.com › best-zsh-plugins
7 Zsh Plugins I Love (And Probably You Will Too)
August 23, 2025 - Once done, it can be directly added to your Oh My Zsh's plugin line. ... The Z plugin is used to quickly jump between recently visited directories.
🌐
Smashing Magazine
smashingmagazine.com › 2015 › 07 › become-command-line-power-user-oh-my-zsh-z
Become A Command-Line Power User With Oh My ZSH And Z — Smashing Magazine
July 11, 2015 - plugins=(git cloudapp node npm bower brew osx extract z) Once you’ve added a plugin, you’ll need to either run source ~/.zshrc or open a new tab. ... git Enabled by default with Oh My Zsh, this enables Git aliases, tab completion and descriptions of all Git commands.
🌐
Reddit
reddit.com › r/zsh › psa: bug in z plugin from oh-my-zsh
r/zsh on Reddit: PSA: Bug in Z plugin from oh-my-zsh
September 18, 2020 -

I did some debugging of the Z plugin from oh-my-zsh recently as some of the functionality didn't seem to work for me. In particular:

  1. _Z_NO_RESOLVE_SYMLINKS wasn't working - it was showing the messy actual path rather than the nice symlinked one.

  2. Also _Z_EXCLUDE_DIRS wasn't working either. It wasn't excluding any directories from its database.

Turns out the first problem was my issue. In my .zshrc I needed to set that variable before loading oh-my-zsh not after (doh!).

But the second issue seems to be a bug in the plugin code. To fix you need to edit the file {oh-my-zsh-directory}/plugins/z/z.sh

Line 60 of that file should read:

case "$*" in "$exclude"*) return;; esac

(the second " should come before the * not after).

I've submitted a pull-request but I have no idea how long these things take.

Hope this helps someone out there!

🌐
Reddit
reddit.com › r/linux4noobs › my favorite oh my zsh plugins
r/linux4noobs on Reddit: My favorite Oh My Zsh plugins
April 8, 2022 -

Here are my favorite Oh My Zsh plugins:

  • colored-man-pages - adds color to man pages

  • command-not-found - suggests packages to install if a command cannot be found

  • fancy-ctrl-z - use ctrl+z to suspend your process and press ctrl+z again to get back (useful if you use terminal text editor)

  • sudo - prefix your current or previous commands with sudo by pressing esc twice (good for noobs!)

  • zoxide - smarter cd command

You can find all the plugins here. I hope it helps!

🌐
Engineering for Data Science
engineeringfordatascience.com › posts › how to set up an amazing terminal for data science with oh-my-zsh plugins
How to set up an amazing terminal for data science with oh-my-zsh plugins | Engineering for Data Science
March 2, 2022 - The zsh-autosuggestions plugin is required to enable autocompletions in zsh. Installation instructions are provided on the installation wiki page of the GitHub repo. The installation is very similar to the syntax highlighting.
🌐
jdhao's digital space
jdhao.github.io › 2019 › 02 › 19 › zsh_advanced_configuration
Boosting Your Productivity on Terminal with Zsh and Plugins · jdhao's digital space
October 16, 2021 - You can manually add a plugin foo to the oh-my-zsh custom folder and activate it in .zshrc like the following: ... The above method works but becomes tedious once you need to install several external plugins. This is when plugin manager comes to help. Just like what you see in Vim, several competing plugin managers are out there for Zsh users, such as antigen, zplug, antibody, zgen1.
🌐
Opensource.com
opensource.com › article › 19 › 9 › adding-plugins-zsh
Adding themes and plugins to Zsh | Opensource.com
September 18, 2019 - If you look at a plugin that claims to be a Z-shell plugin and the code is also compatible with Bash, then you can use it in your Bash shell. Some plugins require Z-shell-specific functions, so this won't work with all of them.