FedoraRHEL Based

How To Install Fish Shell on Fedora 43

Install Fish Shell on Fedora 43

If you have spent any time working in Bash, you know the frustration of no inline feedback, no predictive suggestions, and a configuration process that requires multiple plugins just to reach basic usability. Fish Shell solves all of that out of the box, and this guide shows you exactly how to install Fish Shell on Fedora 43, configure it, extend it with Oh My Fish, and verify your setup from start to finish.

Fish, short for Friendly Interactive Shell, is a fully-equipped Unix shell that works well right after installation, with no extra setup required. It was first written in 2005 by Axel Liljencrantz and is built in C++. Unlike Bash or Zsh, Fish gives you syntax highlighting, autosuggestions, and intelligent tab completions without touching a single config file.

Fedora 43 ships with DNF5 as its default package manager, and Fish is available directly in Fedora’s official repositories. That means you do not need to add any external repository to get started. By the end of this guide, you will have a fully working Fish Shell on Fedora 43 setup, including an optional Oh My Fish framework installation and a clean understanding of how to manage and remove the shell if needed.

What Is Fish Shell and Why Use It?

Before running any commands, it helps to understand what makes Fish worth installing over Bash or Zsh.

Fish Shell focuses on usability and interactivity. The key features that separate it from other shells include:

  • Syntax highlighting: Commands appear in a different color as you type. Invalid commands show in red before you press Enter, catching typos instantly.
  • Autosuggestions: Fish suggests the rest of your command based on history and the current directory. Press the right arrow key to accept the suggestion.
  • Intelligent tab completions: Fish reads your installed man pages and generates completions automatically. No plugin needed.
  • Web-based configuration UI: Run fish_config from the terminal and a local browser page opens where you can pick themes, colors, and prompts visually.
  • Sane scripting syntax: Variable assignment uses set instead of VAR=value, which eliminates an entire category of common Bash scripting bugs.
  • 24-bit true color support: Fish supports full VGA color in terminals that support it.

The difference between Fish and Zsh is also worth noting. Zsh ships with minimal defaults and relies heavily on Oh My Zsh for a comparable experience. Fish works well by default and only needs a framework like Oh My Fish for theme and plugin management beyond its built-in features.

Prerequisites

Before you begin, confirm the following:

  • A system running Fedora 43 (Workstation or Server edition)
  • A non-root user account with sudo privileges
  • An active internet connection for downloading packages
  • Access to a terminal emulator (on Fedora Workstation: Activities > search “Terminal”)
  • Basic familiarity with running commands in a terminal

You do not need to be a seasoned sysadmin to follow this guide. Each command is explained so you understand what it does, not just how to copy and paste it.

Step 1: Update Your Fedora 43 System

Always update your system before installing new software. Outdated package metadata can cause dependency conflicts that are annoying to debug after the fact.

Run the following two commands:

sudo dnf clean all
sudo dnf update -y

The first command clears the DNF cache to force a fresh metadata download. The second updates all installed packages on your system.

If the update includes a kernel upgrade, reboot before continuing:

sudo reboot

After the system comes back up, check whether Fish is already installed. This avoids reinstalling a package that is already present:

fish --version

If you see a version number like fish, version 3.7.1, Fish is already installed and you can skip to Step 4. If you see command not found, continue with Step 2.

Step 2: Install Fish Shell on Fedora 43

Fedora 43 provides two solid ways to install Fish Shell on Fedora 43. The first method uses Fedora’s official DNF repository and is the recommended path for most users. The second method pulls from the openSUSE Build Service for users who need the absolute latest version.

Method 1: Install Fish Shell via DNF (Recommended)

Fish is available in Fedora’s default repositories, so no third-party repository needs to be added. This keeps your system clean and ensures the package is signed with Fedora’s GPG key.

Run the install command:

sudo dnf install fish -y

DNF will resolve any required dependencies, show you the total download size, and install the package. The -y flag auto-confirms the prompt so you do not need to type y manually.

Verify the installation:

fish --version

Expected output:

fish, version 3.7.1

The version number may differ depending on what Fedora 43’s repositories currently ship, but any 3.x or 4.x version confirms a successful install.

Method 2: Install Fish Shell via the openSUSE Build Service Repository

Use this method when you want a version of Fish that is newer than what Fedora’s default repositories provide. The openSUSE Build Service (OBS) maintains an up-to-date Fish repository for each major Fedora release.

Add the Fedora 43 Fish repository:

sudo dnf config-manager addrepo --from-repofile=https://download.opensuse.org/repositories/shells:fish/Fedora_43/shells:fish.repo

Update the package metadata to enable the new repository:

sudo dnf update -y

Install Fish Shell:

sudo dnf install fish -y

When prompted to import a GPG key, confirm by typing y. The key belongs to the shells:fish OBS Project and validates the integrity of the package. Never skip this step on a production system.

Verify the install:

fish --version

Confirm the new repository appears in your repo list:

dnf repolist

You should see shells_fish listed alongside the standard Fedora repositories.

Step 3: Launch Fish Shell

After installation, Fish is not yet your active shell. You need to launch it manually to test it first.

Start a Fish session from your current terminal:

fish

You will see the Fish welcome prompt:

Welcome to fish, the friendly interactive shell
Type help for instructions on how to use fish
yourusername@fedora ~>

Test autosuggestions right away. Start typing sudo dnf and pause. Fish will suggest the last command you ran that starts with those characters. Press the right arrow key to accept the suggestion or keep typing to ignore it.

To exit the Fish session and return to Bash:

exit

You can also press Ctrl+D to exit. At this point, Fish is installed and verified. The next step makes it your default shell.

Step 4: Set Fish as the Default Shell on Fedora 43

Launching Fish manually works for testing, but to make it load every time you open a terminal, you need to set it as your default login shell. This involves registering Fish as a valid shell and then pointing your user account to it.

Install the chsh Utility

The chsh command changes the default shell for a user. On Fedora 43, it comes from the util-linux-user package, which may not be installed by default:

sudo dnf install util-linux-user -y

Register Fish as a Valid Shell

Linux systems maintain a list of valid login shells in /etc/shells. Fish must appear in that list before chsh will accept it:

echo /usr/bin/fish | sudo tee -a /etc/shells

This appends /usr/bin/fish to the /etc/shells file. The tee -a flag appends rather than overwrites, so your existing entries stay intact.

Change the Default Shell

Now point your user account to Fish:

chsh -s /usr/bin/fish

Enter your user password when prompted. Log out and log back in for the change to take effect.

After logging back in, verify the change:

echo $SHELL

Expected output:

/usr/bin/fish

Important note for GNOME users: In rare cases, setting Fish as the system-wide login shell can trigger a GNOME login loop. If this happens, press Ctrl+Alt+F3 to access a TTY session, log in, and run chsh -s /bin/bash to revert. As an alternative that avoids this issue entirely, set Fish only inside your terminal emulator. In GNOME Terminal, go to Edit > Preferences > your profile > Command, enable “Run a custom command instead of my shell,” and enter /usr/bin/fish.

Step 5: Configure Fish Shell on Fedora 43

One of the biggest advantages of configuring Fish Shell on Fedora 43 is that it works well without any manual setup. That said, customizing it unlocks its full potential for day-to-day work.

Locate and Create the Config File

Fish reads its per-user configuration from ~/.config/fish/config.fish. This file does not exist by default and must be created manually.

mkdir -p ~/.config/fish
touch ~/.config/fish/config.fish

The system-wide configuration lives at /etc/fish/config.fish and applies to all users on the machine.

Add Environment Variables

Fish uses a different syntax from Bash for setting variables. Use set with the -gx flags to set a global exported variable:

set -gx PATH $PATH ~/bin

This adds ~/bin to your PATH permanently. The -g flag makes it global (available to all Fish sessions), and -x exports it to child processes.

Create Persistent Aliases

Fish handles aliases differently from Bash. You define them and then save them as functions:

alias ll='ls -lh'
funcsave ll

The funcsave command saves the alias as a function file in ~/.config/fish/functions/ll.fish, making it available in every future Fish session automatically.

Use the Web Configuration UI

Fish ships with a built-in browser-based configuration tool. From inside a Fish session, run:

fish_config

This opens a local web page where you can visually select themes, edit prompts, browse shell history, and manage abbreviations without touching any config file. This is the fastest way to customize your shell without memorizing configuration syntax.

Step 6: Install and Use Oh My Fish (OMF)

Oh My Fish is a framework for Fish Shell that lets you install themes and plugins with a single command. Think of it as a package manager for your shell’s appearance and behavior, similar in concept to what Oh My Zsh does for Zsh.

Prerequisites for Oh My Fish

Before installing, confirm the following are available on your system:

  • Fish Shell version 2.2 or later (already satisfied)
  • Git version 1.9.5 or later

Install Git if it is not already present:

sudo dnf install git -y
git --version

Expected output: git version 2.47.1 or later.

Install Oh My Fish

Run the following command from inside a Fish session (not a Bash session):

curl https://raw.githubusercontent.com/oh-my-fish/oh-my-fish/master/bin/install | fish

You will see OMF clone its repository from GitHub, write a bootstrap file to ~/.config/fish/conf.d/omf.fish, and install the default package. The final output should read:

Installation successful!
Welcome to fish, the friendly interactive shell

Use the OMF Management Tool

Once installed, OMF gives you a clean command-line interface for managing themes and plugins. Here are the most useful commands:

Command What It Does
omf list Lists all installed packages and themes
omf theme Shows all available and installed themes
omf install bobthefish Installs the bobthefish theme
omf theme bobthefish Applies the bobthefish theme
omf update Updates all installed OMF packages
omf remove <name> Removes a package or theme
omf destroy Uninstalls Oh My Fish completely

Recommended Themes to Try

Three popular OMF themes that work well on Fedora desktops and servers:

  • bobthefish: A powerline-style prompt with Git branch, Python virtualenv, and timestamp support. Good for developers.
  • pure: A minimal, fast-loading prompt that shows only what you need. Good for servers.
  • agnoster: A Git-aware prompt with clean iconography. Works best with a Nerd Font installed.

Step 7: Verify Your Complete Setup

Before considering this a done Linux server tutorial, confirm that every piece of the setup is working correctly.

Run each check one at a time:

fish --version

Confirms Fish is installed and shows the version.

echo $SHELL

Confirms Fish is set as the default shell. Output should be /usr/bin/fish.

omf list

Confirms Oh My Fish is installed and lists your current packages and themes.

Open a new terminal window and confirm Fish loads automatically with your chosen prompt. If OMF applied a theme, you should see it render immediately.

Useful Fish Shell Commands to Get Started

These commands cover the daily workflows you will reach for most often as you settle into Fish:

Command What It Does
fish Launch a Fish session
fish_config Open browser-based config UI
help Open Fish documentation in a browser
funced <name> Interactively edit a function
funcsave <name> Save a function permanently to disk
set -gx VAR value Set a global environment variable
type <command> Show the source of a command (alias, function, or binary)
history Browse your command history
fish_add_path /path Permanently add a directory to PATH
source ~/.config/fish/config.fish Reload your config without restarting

Troubleshooting Common Issues

Even a straightforward install can produce a few edge-case errors. Here are the five most common problems and how to fix them.

1. fish: command not found after installation

Run which fish to check whether the binary exists. If it returns nothing, re-run the install:

sudo dnf install fish -y

If the issue persists with Method 2, confirm the OBS repository is active with dnf repolist.

2. GNOME login loop after chsh

Press Ctrl+Alt+F3 to access a TTY. Log in and revert to Bash:

chsh -s /bin/bash

Log out, switch back to the graphical session with Ctrl+Alt+F2, and use the GNOME Terminal profile method instead.

3. chsh: command not found

The util-linux-user package is missing. Install it:

sudo dnf install util-linux-user -y

4. Oh My Fish installation fails

Confirm two things: Git is installed (git --version) and you are running the install command from inside a Fish session. Running the curl | fish command from a Bash prompt will fail because fish is being called as a command, not as the active shell.

5. Config file changes not taking effect

Reload the config file without restarting your terminal:

source ~/.config/fish/config.fish

This re-executes the config file in the current session.

How to Uninstall Fish Shell from Fedora 43

If you decide Fish is not the right shell for your workflow, removing it cleanly takes four steps.

Step 1: If Fish is your current default shell, revert to Bash first:

chsh -s /bin/bash

Log out and log back in to confirm Bash is active.

Step 2: If Oh My Fish is installed, uninstall it first from inside a Fish session:

omf destroy

Step 3: Remove Fish using DNF:

sudo dnf remove fish -y

Step 4 (Optional): Remove all Fish configuration files:

rm -rf ~/.config/fish

This removes your themes, functions, aliases, and config history. Skip this step if you plan to reinstall Fish later and want to keep your settings.

Congratulations! You have successfully installed Fish Shell. Thanks for using this tutorial for installing the Fish Shell on your Fedora 43 Linux system. For additional or useful information, we recommend you check the official Fish Shell website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!

r00t

r00t is a dedicated and highly skilled Linux Systems Administrator with over a decade of progressive experience in designing, deploying, and maintaining enterprise-grade Linux infrastructure. His professional journey began in the telecommunications industry, where early exposure to Unix-based operating systems ignited a deep and enduring passion for open-source technologies and server administration.​ Throughout his career, r00t has demonstrated exceptional proficiency in managing large-scale Linux environments, overseeing more than 300 servers across development, staging, and production platforms while consistently achieving 99.9% system uptime. He holds advanced competencies in Red Hat Enterprise Linux (RHEL), Debian, and Ubuntu distributions, complemented by hands-on expertise in automation tools such as Ansible, Terraform, Bash scripting, and Python.
Back to top button