Google Gemini Keyboard Shortcuts & Commands (16)
Complete collection of 16 Google Gemini keyboard shortcuts and commands. Browse all shortcuts organized by category with our interactive search tool.
Related Shortcut Pages
Search all Google Gemini shortcuts interactively with real-time filtering
Open Interactive Shortcut FinderAll Shortcuts
Web App
| Shortcut | Action | Description |
|---|---|---|
| Enter | Send Message | Sends the prompt in gemini.google.com. |
| Shift + Enter | New Line | Line break without sending. |
| Ctrl + Shift + C | Copy Response | Copies the last response. |
| Ctrl + Z | Undo | Undo in the prompt box. |
| Ctrl + / | Show Shortcuts | Opens the in-app shortcut list. |
Gemini CLI — Slash Commands
| Shortcut | Action | Description |
|---|---|---|
| /help | Show Help | Lists commands and keybindings (alias /?). |
| /clear | Clear Screen | Wipes the terminal display (Ctrl + L does the same). |
| /quit | Exit CLI | Ends the session (alias /exit). |
| /tools | List Tools | Shows the tools available to the model. |
| /mcp | MCP Servers | Lists configured MCP servers and their tools. |
| /memory | Manage Memory | Show, add to, or refresh the hierarchical GEMINI.md context. |
| /stats | Session Stats | Token usage and savings for the session. |
| /chat | Save / Resume Chat | Checkpoint conversations: /chat save, /chat resume, /chat list. |
| /compress | Compress Context | Replaces the whole context with a summary to save tokens. |
| /copy | Copy Last Output | Copies the last response to the clipboard. |
| /theme | Change Theme | Opens the visual theme picker. |
| /vim | Vim Mode | Toggles vim-style editing in the input field. |
Gemini CLI — Editing Keys
| Shortcut | Action | Description |
|---|---|---|
| Ctrl + A | Start of Line | Moves the cursor to the beginning of the input. |
| Ctrl + E | End of Line | Moves the cursor to the end of the input. |
| Alt + B | Word Left | Moves back one word. |
| Alt + F | Word Right | Moves forward one word. |
| Ctrl + W | Delete Word Left | Deletes the previous word. |
| Ctrl + K | Delete to End | Deletes from the cursor to the end of the line. |
| Ctrl + U | Delete to Start | Deletes from the cursor to the start of the line. |
| Ctrl + Z | Undo Edit | Undoes the last text edit in the input. |
Gemini CLI — Control & History
| Shortcut | Action | Description |
|---|---|---|
| Ctrl + C | Cancel / Quit | Cancels the current request; quits when input is empty. |
| Ctrl + D | Exit on Empty | Exits the CLI when the input buffer is empty. |
| Esc | Dismiss / Cancel | Closes dialogs or cancels the current focus. |
| Ctrl + P | Previous History | Recalls the previous prompt (with Up arrow). |
| Ctrl + N | Next History | Moves forward through prompt history. |
| Ctrl + R | Search History | Reverse-search through past prompts. |
Gemini CLI — Invocation & Flags
| Shortcut | Action | Description |
|---|---|---|
| gemini | Start Interactive Session | Launches the REPL in the current directory. |
| gemini -p "prompt" | One-Shot Prompt | Runs a single prompt non-interactively and prints the answer. |
| cat file | gemini | Pipe Input | Feeds file contents as context via stdin. |
| --model <name> | Select Model | Chooses the Gemini model for the session. |
| --yolo | Auto-Approve Actions | Skips confirmation prompts for tool calls — use with care. |
| --debug | Debug Output | Verbose logging for troubleshooting. |
One name, two surfaces
“Gemini shortcuts” means two unrelated things. The web app at gemini.google.com has a handful of chat keys (and, notably, no official published table — Ctrl + / shows the in-app list). The Gemini CLI is a different animal: an open-source terminal agent from Google with a documented command set, slash commands, and full readline-style editing. The CLI is where the depth is, and everything in its sections below comes from Google's own reference docs.
Slash commands run the session
Inside the CLI, / commands manage everything around the conversation. /chat save and /chat resume checkpoint long sessions; /compress replaces the whole context with a summary when you're burning tokens; /memory shows and refreshes the hierarchical GEMINI.md context files that steer the agent; /tools and /mcp reveal what the model can actually do in your environment. /stats keeps the token bill honest, and /vim flips the input line to vi-style editing if that's home.
The input line is a real editor
Gemini CLI's editing keys mirror bash: Ctrl + A/E for line ends, Alt + B/F by word, Ctrl + W/K/U for deletions, plus genuine undo on Ctrl + Z. History works the same way — Ctrl + R reverse-searches past prompts. The two exit paths differ deliberately: Ctrl + C cancels the current request (and quits only on an empty line), while Ctrl + D on an empty buffer exits outright. For scripting, skip the REPL entirely: gemini -p runs one prompt and prints, and piping (cat file | gemini) feeds context through stdin.
Frequently asked questions
Does the Gemini web app have official keyboard shortcuts?
Google doesn't publish a table for gemini.google.com; Ctrl+/ opens the in-app list. The CLI, by contrast, has fully documented commands and keys.
How do I save and resume a conversation in Gemini CLI?
/chat save <tag> checkpoints the session; /chat resume <tag> restores it later, and /chat list shows saved tags.
What does /compress do in Gemini CLI?
It replaces the entire conversation context with a model-written summary — the escape hatch when a long session approaches the context limit or token costs climb.
What's the difference between Ctrl+C and Ctrl+D in Gemini CLI?
Ctrl+C cancels the in-flight request, and quits if the input is empty; Ctrl+D exits only when the input buffer is empty — the classic terminal EOF.
How do I run Gemini CLI non-interactively?
gemini -p "your prompt" runs once and prints the answer — pipeable and scriptable. stdin works too: cat notes.md | gemini.
What is the --yolo flag in Gemini CLI?
It auto-approves the agent's tool calls (file edits, shell commands) without asking. Powerful for automation, risky by design — use it in sandboxes.
🤖 Ask AI about Gemini shortcuts
Open your assistant with this page preloaded as the source — great for follow-up questions like "which of these work in other apps?"