FISH_TAB_TITLE(1)

✨ FISH_TAB_TITLE ✨ (section 1 of the fish-shell manuals, bestie πŸ’…)

okay so this page is literally about fish_tab_title β€” it's from fish-shell, and it's the whole entire vibe of "how do I make my terminal tab say something cute instead of the default boring-ness". let's get into it πŸŽ€


πŸ’– NAME πŸ’–

fish_tab_title β€” define the terminal tab's title. that's it, that's the whole job, and honestly? iconic.


🌸 SYNOPSIS 🌸

fish_title
fish_tab_title
function fish_title
    ...
end
function fish_tab_title
    ...
end

πŸ¦‹ DESCRIPTION πŸ¦‹

so here's the tea β˜• β€” fish_title is a function, and fish runs it before and after a new command gets executed or put into the foreground, and whatever it prints becomes your titlebar message. like, it's giving "your terminal is a whole aesthetic now" ✨

the first argument to fish_title contains the most recently executed foreground command as a string, if there is one. yup, argv[1] is literally the receipts of what you just ran πŸ“

⚠️ heads up bestie β€” this requires that your terminal supports [programmable titles](<#term-compat-osc-0>) and that the feature is turned on. no support, no title. them's the rules 😭

want to disable setting the title entirely? just use an empty function, it's like, the simplest slay ever (see the examples below, i gotchu 🫢).

and if you want the terminal tab title to be something other than the terminal window title β€” yes those are two different things, keep up πŸ’€ β€” then you define the fish_tab_title function. it works exactly like fish_title but it overrides that one. main character energy, literally πŸ‘‘


πŸŽ€ EXAMPLE πŸŽ€

a simple title, ngl this one ate:

function fish_title
    set -q argv[1]; or set argv fish
    # Looks like ~/d/fish: git log
    # or /e/apt: fish
    echo (fish_prompt_pwd_dir_length=1 prompt_pwd): $argv;
end

do not change the title β€” for when you simply cannot be bothered πŸ™ˆ:

function fish_title
end

change the tab title only, baby steps πŸ’œ:

function fish_tab_title
    echo fish $fish_pid
end

fish-shell developers β€” credit where credit is due, we stan πŸ’–


and that's the whole page, no cap 🧚✨ this was fish-shell manuals, version 4.9, dated Sep 08, 2026 β€” go forth and make your tabs cute, bestie, i believe in you πŸ«ΆπŸ’…πŸ“

πŸ“¦ where this page comes from
  • arch rolling: fish 4.9.3-1 Β· GPL-2.0-only AND BSD-3-Clause AND ISC AND MIT AND PSF-2.0
  • πŸ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms