Skip to content

Instantly share code, notes, and snippets.

@hensg
Forked from trashhalo/ghostty-shortcuts.md
Created February 5, 2025 17:47
Show Gist options
  • Select an option

  • Save hensg/43bc71c21d1f79385892352a390aa2ca to your computer and use it in GitHub Desktop.

Select an option

Save hensg/43bc71c21d1f79385892352a390aa2ca to your computer and use it in GitHub Desktop.

Ghostty Keyboard Shortcuts

Default keyboard shortcuts for Ghostty terminal emulator. Platform-specific differences are noted where applicable.

Window Management

Action Windows/Linux macOS
New window Ctrl+Shift+N Cmd+N
Close window Alt+F4 Cmd+Shift+W
Close all windows - Cmd+Shift+Option+W
Toggle fullscreen Ctrl+Enter Cmd+Enter or Cmd+Ctrl+F
Quit application Ctrl+Shift+Q Cmd+Q

Tab Management

Action Windows/Linux macOS
New tab Ctrl+Shift+T Cmd+T
Close tab/surface Ctrl+Shift+W Cmd+W
Previous tab Ctrl+Shift+Tab, Ctrl+Shift+Left, Ctrl+Page Up Cmd+Shift+[
Next tab Ctrl+Tab, Ctrl+Shift+Right, Ctrl+Page Down Cmd+Shift+]
Go to tab 1-8 Alt+[1-8] Cmd+[1-8]
Go to last tab Alt+9 Cmd+9
Move tab - -

Split Management

Action Windows/Linux macOS
New split (right) Ctrl+Shift+O Cmd+D
New split (down) Ctrl+Shift+E Cmd+Shift+D
Focus previous split Ctrl+Super+[ Cmd+[
Focus next split Ctrl+Super+] Cmd+]
Focus split up Ctrl+Alt+Up Cmd+Option+Up
Focus split down Ctrl+Alt+Down Cmd+Option+Down
Focus split left Ctrl+Alt+Left Cmd+Option+Left
Focus split right Ctrl+Alt+Right Cmd+Option+Right
Toggle split zoom Ctrl+Shift+Enter Cmd+Shift+Enter
Resize split up Ctrl+Super+Shift+Up Cmd+Ctrl+Up
Resize split down Ctrl+Super+Shift+Down Cmd+Ctrl+Down
Resize split left Ctrl+Super+Shift+Left Cmd+Ctrl+Left
Resize split right Ctrl+Super+Shift+Right Cmd+Ctrl+Right
Equalize splits Ctrl+Super+Shift+= Cmd+Ctrl+=

Copy & Paste

Action Windows/Linux macOS
Copy Ctrl+Shift+C Cmd+C
Paste Ctrl+Shift+V Cmd+V
Paste from selection Shift+Insert -

Text Navigation

Action Windows/Linux macOS
Scroll to top Shift+Home Cmd+Home
Scroll to bottom Shift+End Cmd+End
Scroll page up Shift+Page Up Cmd+Page Up
Scroll page down Shift+Page Down Cmd+Page Down
Jump to previous prompt Ctrl+Shift+Page Up Cmd+Up
Jump to next prompt Ctrl+Shift+Page Down Cmd+Down
Clear screen - Cmd+K

Font Size

Action Windows/Linux macOS
Increase font size Ctrl++/Ctrl+= Cmd++/Cmd+=
Decrease font size Ctrl+- Cmd+-
Reset font size Ctrl+0 Cmd+0

Configuration

Action Windows/Linux macOS
Open config Ctrl+, Cmd+,
Reload config Ctrl+Shift+, Cmd+Shift+,

Inspector

Action Windows/Linux macOS
Toggle inspector Ctrl+Shift+I Cmd+Option+I

Scrollback

Action Windows/Linux macOS
Write scrollback to file (paste) Ctrl+Shift+J Cmd+Shift+J
Write scrollback to file (open) Ctrl+Shift+Alt+J Cmd+Shift+Option+J

Note: These are the default keybindings. All keybindings can be customized through the configuration file using the keybind option.

@aq1
Copy link

aq1 commented Feb 21, 2025

I wonder why I found it here and not in official docs.

@mzgivb
Copy link

mzgivb commented Feb 28, 2025

thanks

@CuddlyBunion341
Copy link

Thanks for saving me a headache 👍

@NEO-LAX
Copy link

NEO-LAX commented Mar 17, 2025

thx

@markbabin
Copy link

I guess they feel they are so "native" they dont really have to add them to their docs hehe

@LaurenceGuws
Copy link

❤️❤️❤️❤️❤️❤️❤️❤️❤️

@Samk13
Copy link

Samk13 commented Mar 30, 2025

What is the shortcut to find or search on Mac?

@qu8n
Copy link

qu8n commented Apr 6, 2025

@Samk13 Search is not yet supported. As a temporary solution, I added this line in the config on my macOS:

keybind = "ctrl+f=write_scrollback_file:open"

Pressing Ctrl + F now opens up a textedit file containing the content of the current terminal's output, and you can Cmd + F to search in that file. Not elegant but a fine stopgap solution for me.

@Samk13
Copy link

Samk13 commented Apr 6, 2025

@qu8n, cool workaround! I later noticed the limitation too, and I'm currently using tmux to get by while the issue gets sorted out using Ctrl-b [ / foo b n. I’ll give your method a try though. Appreciate you sharing it!

@jenil777007
Copy link

Thanks. This is much helpful.

BTW, how do we close a split?

@sudip-poudel
Copy link

@jenil777007 Ctrl + Alt + D in linux

@SquidBytes
Copy link

@jenil777007 Ctrl + Alt + D in linux

That doesn't work for me. I feel like I've tried many different key combinations and other terminal defaults.
I can not figure out how to close a split, or what to add to the configuration to do this.

@jenil777007
Copy link

Hey folks, for mac to close a split I think Cmd + W works

@geon
Copy link

geon commented May 11, 2025

@jenil777007

Closing a split on macos is Ctrl + D.

@jon-hotaisle
Copy link

Maybe not as nice of formatting, but you can also do it with this: ghostty +list-keybinds --default

@byteoxo
Copy link

byteoxo commented Jul 25, 2025

tky

@timbogdanov
Copy link

@Samk13 Search is not yet supported. As a temporary solution, I added this line in the config on my macOS:

keybind = "ctrl+f=write_scrollback_file:open"

Pressing Ctrl + F now opens up a textedit file containing the content of the current terminal's output, and you can Cmd + F to search in that file. Not elegant but a fine stopgap solution for me.

wild

@vl-ivanov
Copy link

I wonder why I found it here and not in official docs.

me too!

@rubywwwilde
Copy link

wow, I just randomly type "Cmd+Shift+" and it showed me all the sessions!

@jorgeobnd
Copy link

Yooo, someone know how change the cursor style, like block or line?

@rubywwwilde
Copy link

@jorgeobnd the only thing I've achieved to do is to make it thick: adjust-cursor-thickness = 3
there is this option in settings: https://ghostty.org/docs/config/reference#cursor-style

though, it did not work for me. probably I would need to configure fish for that

@avinashkanaujiya
Copy link

avinashkanaujiya commented Aug 26, 2025

How to set a keyboard shortcut for activating the dropdown terminal on macOS, or what is the shortcut?
Nevermind, found it.

UPDATE
@rubywwwilde keybind = global:cmd+grave_accent=toggle_quick_terminal Add this to your config and then use the command plus tilde key combination to toggle the drop-down terminal. Here, the grave accent is the tilde key on the keyboard.

@rubywwwilde
Copy link

rubywwwilde commented Aug 27, 2025

@avinashkanaujiya what is the shortcut?

UPDATE Thank you

@GeoffreyPlitt
Copy link

Is there really still no Search? I need Search 1000x more than I need splits

@petipoua
Copy link

thank you! why the hell isn't this found in the Ghostty docs smh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment