Antigravity CLI is the terminal interface for Google Antigravity. It lets you run coding agents, review changes, and manage parallel work from a local shell, SSH session, or headless environment.
It uses the same agent harness as Antigravity 2.0, with terminal controls for code search, execution modes, permissions, subagents, tasks, skills, and MCP servers.
Learn More About Antigravity CLI
This cheat sheet is for moments when you already know what you want to do and need the exact command.
Start with the quick reference table, then use the sections below for setup, slash commands, shortcuts, permissions, sandbox settings, subagents, MCP, and Gemini CLI migration.
Updated for Antigravity CLI 1.1.5 on July 20, 2026
Antigravity CLI Cheatsheet
Antigravity CLI quick reference
| Task | Command |
|---|---|
| Start CLI | agy |
| Command menu | / |
| Search code | /codesearch, /cs, /search |
| Help | ?, /usage |
| Settings | /config, /settings |
| Permissions | /permissions |
| Model | /model, --model <slug> |
| Reasoning effort | /effort, /effort <level>, --effort <level> |
| Plan mode | /plan |
| Cycle execution mode | Shift+Tab |
| File diff | /diff |
| Resume session | /resume |
| Rewind session | /rewind, /undo |
| Fork session | /fork, /branch |
| Add folder | /add-dir <path> |
| Open file | /open <path> |
| Run shell command | !<command> |
| Print mode | agy -p "<prompt>" |
| Custom agent | agy --agent <name> |
| Subagents | /agents |
| Task logs | /tasks |
| Skills | /skills |
| MCP servers | /mcp |
| Hooks | /hooks |
| Log out | /logout |
| Exit | /exit |
What changed in Antigravity CLI 1.1.5
| Change | What it means |
|---|---|
/effort | View or change reasoning effort without restarting the CLI. |
--effort <level> | Choose a reasoning-effort variant when launching. |
| Model slugs | Use the stable model names shown in /model with --model. |
| Custom-agent model | Add model to agent frontmatter to select a subagent tier; omit it to inherit the parent model. |
| Command chains | Combine leading slash commands such as /plan /grill-me in one prompt. |
/diff | Scrolling remains stable when lines wrap or comments expand. |
Install Antigravity CLI
Antigravity CLI installs the agy binary. It runs on macOS, Linux, and Windows.
macOS and Linux
The native installer downloads the executable to ~/.local/bin/agy.
curl -fsSL https://antigravity.google/cli/install.sh | bashWindows PowerShell
The Windows installer registers agy in the local user directory at C:\Users\<Username>\AppData\Local\agy\bin.
irm https://antigravity.google/cli/install.ps1 | iexWindows CMD
curl -fsSL https://antigravity.google/cli/install.cmd -o install.cmd && install.cmd && del install.cmdInstall flags
| Flag | Use |
|---|---|
--skip-aliases | Keep existing agy or antigravity aliases. |
--skip-path | Do not edit shell profile PATH. |
Launch flags and headless mode
| Command or flag | Use |
|---|---|
agy -p "<prompt>" | Run once and print the result. |
--model <slug> | Select a model with a stable model slug. |
--effort <level> | Select the model’s reasoning-effort variant at launch. |
--mode <mode> | Start in default, accept-edits, or plan mode. |
--agent <name> | Start with a custom agent. |
agy agent, agy agents | List available custom agents. |
--project <project> | Open an existing project. |
--new-project <name> | Create a project. |
--sandbox | Enable terminal sandboxing for the session. |
AGY_CLI_CMD_OUTPUT_PERCENTAGE | Limit terminal output shown in the TUI. |
Print mode is designed for scripts and CI jobs. If a tool needs approval, Antigravity CLI denies it unless a matching allow rule exists and prints guidance to stderr. Invalid model names and other print-mode failures return a nonzero exit code instead of waiting for interactive input.
Authentication and SSH login
When you run agy locally, the CLI checks your operating system keyring first. On macOS it uses Apple Keychain. On Linux it uses Secret Service or dbus. On Windows it uses Windows Credential Manager. If a valid token exists, Antigravity CLI signs in silently.
If no saved session exists, the CLI opens your default browser. Sign in with your approved account, then return to the terminal.
SSH login uses a manual browser loop:
- Run
agyin the remote terminal. - Copy the authorization URL printed by the CLI.
- Open the URL in a local browser.
- Sign in and copy the authorization code.
- Paste the code back into the remote terminal.
Use /logout when you need to disconnect the current account and purge saved authentication profiles.
On Linux servers and containers without D-Bus, the CLI falls back cleanly when no Secret Service keyring is available. OAuth codes can also be pasted in print mode when a terminal is attached; a fully headless process fails instead of blocking on a hidden prompt.
Core slash commands
Slash commands are the fastest way to control Antigravity CLI. Type / in the prompt box to open the command menu.
Workspace and files
| Command | Purpose |
|---|---|
/codesearch (/cs, /search) | Search workspace code interactively. |
/add-dir <path> | Add a directory to the workspace. |
/diff | Show diffs for modified files. |
/open <path> | Open a path in the default editor. |
/clear | Clear the terminal and conversation context. |
/codesearch treats the query as a regular expression by default. Use -F or --literal for an exact string. Add f: or file: globs to include or exclude paths.
Conversation control
| Command | Purpose |
|---|---|
/resume (/switch, /conversation) | Load previous threads. |
/rewind (/undo) | Roll back conversation history. |
/fork (/branch) | Create a parallel session. |
/rename <name> | Rename the thread. |
/exit | Close the CLI. |
Settings and agent behavior
| Command | Purpose |
|---|---|
/config or /settings | Open the settings editor. |
/permissions | Switch permission presets. |
/model | Choose a model and its available reasoning effort. |
/effort or /effort <level> | View or set reasoning effort for the current model. |
/plan | Enter plan mode. |
/keybindings | Edit keyboard shortcuts. |
/statusline | Customize the status bar. |
/title [on/off] | Control terminal title updates. |
Tools, subagents, and accounts
| Command | Purpose |
|---|---|
/agents | Open the Agent Manager Panel for background subagents. |
/tasks | Open the Task Manager Panel for background shell logs. |
/skills | Browse loaded local and global Agent Skills. |
/mcp | Open the MCP server manager. |
/hooks | Browse active pre-flight and post-format hooks. |
/btw <query> | Ask a side question in the background without interrupting the main conversation. |
/usage | Open the offline developer help manual. |
/logout | Disconnect the account and remove saved tokens. |
Keyboard shortcuts
Keybindings can change if you customize them. Use /keybindings to inspect or edit your current setup.
| Shortcut | Action |
|---|---|
Enter | Submit the prompt or selection. |
Shift+Enter, Ctrl+J, Alt+Enter | Insert a newline. |
Shift+Tab | Cycle default, accept-edits, and plan modes. |
Esc | Close a panel or stop a stream. |
Ctrl+C | Cancel active work; press twice to exit. |
Ctrl+D | Forward-delete text; exit on an empty prompt. |
Ctrl+L | Clear the terminal buffer. |
Ctrl+V | Paste clipboard content. |
Alt+V | Alternative paste on Windows. |
Ctrl+G | Open the prompt, diff, or confirmation in $EDITOR. |
Ctrl+O | Toggle detailed tool output. |
Ctrl+R | Open artifact review. |
f | Open the full diff from file review. |
/ in artifact details | Search the current artifact. |
n, N during search | Move to the next or previous match. |
Shift+N in diff view | Move to the previous diff. |
Alt+J | Focus the next subagent awaiting approval. |
Ctrl+K | Approve a pending subagent action. |
Ctrl+A, Ctrl+E | Move to the start or end of the line. |
Ctrl+Z, Ctrl+Shift+Z | Undo or redo text edits. |
PgUp, PgDn | Scroll the active viewport. |
Tab | Accept slash-command completion. |
y, n at confirmation | Approve or reject a proposal. |
A | Approve all artifacts in review. |
Execution modes
Choose a mode under Agent Mode in /settings, pass it with --mode, or press Shift+Tab to cycle through the three options.
| Mode | Behavior |
|---|---|
default | Review file writes before they run. |
accept-edits | Accept file edits automatically. |
plan | Plan without applying edits. |
Settings, permissions, and sandbox
Antigravity CLI stores its main settings in:
~/.gemini/antigravity-cli/settings.jsonIt stores custom keybindings in:
~/.gemini/antigravity-cli/keybindings.jsonYou can edit settings through /config or /settings. Some settings can also be overridden at launch with flags such as --sandbox or --dangerously-skip-permissions. A launch flag applies to the current session until restart, even if you edit the persistent setting on disk.
Settings worth knowing
| Setting | Default and use |
|---|---|
colorScheme | "terminal"; color theme. |
altScreenMode | "default"; screen buffer. |
toolPermission | "request-review"; tool approvals. |
artifactReviewPolicy | "asks-for-review"; code review flow. |
notifications | false; completion alerts. |
showTips | true; prompt tips. |
showFeedbackSurvey | true; feedback prompts. |
editor | "auto"; external editor. |
allowNonWorkspaceAccess | false; outside-root file access. |
enableTerminalSandbox | false; command sandboxing. |
enableTelemetry | true; metrics and crash logs. |
verbosity | "high"; output detail. |
runningLightSpeed | "medium"; progress animation. |
Permission presets
| Preset | Use |
|---|---|
request-review | Default for most coding work. |
proceed-in-sandbox | Auto-proceed inside sandbox. |
always-proceed | No prompts; controlled workspaces only. |
strict | Prompt for all non-read tools. |
Use permission.allow for file writes and commands that should run without another prompt. Command rules use strict matching by default. Prefix a rule with regex: only when you intend to use a regular expression.
Terminal sandbox
Set enableTerminalSandbox to true if you want local agent commands to run inside OS containment boundaries.
{
"enableTerminalSandbox": true
}When sandbox mode is enabled, Antigravity CLI can still ask whether a trusted command should run without sandbox restrictions. When sandbox mode is disabled, a confirmation prompt can offer to run a specific risky command inside the sandbox.
For regular project work, start with request-review, keep allowNonWorkspaceAccess set to false, and inspect /diff before accepting code changes.
Subagents, tasks, skills, plugins, and MCP
Antigravity CLI can run background subagents, and those subagents can delegate work to nested subagents. The primary conversation stays active while delegated tasks run.
Use /agents to open the Agent Manager Panel. It shows active and completed subagents, their status, and the step each subagent is running. Select a subagent to inspect its full conversation, tool logs, and pending approvals.
Use /tasks when you need shell execution logs. Use /skills to browse loaded Agent Skills. Use /mcp to manage Model Context Protocol servers. Use /hooks to inspect active pre-flight and post-format hooks.
Use --agent <name> to select a custom agent at launch. The agent and agents subcommands list available agents. Add model to custom-agent frontmatter when a subagent should use a selected model tier; otherwise it inherits the parent model. Global agent configuration lives under ~/.gemini/config/.
Plugins are staged under:
~/.gemini/antigravity-cli/plugins/<plugin_name>/A plugin can include a required plugin.json file plus optional mcp_config.json, hooks.json, skills/, agents/, and rules/ directories.
Gemini CLI migration
Antigravity CLI supports migration from Gemini CLI. On first launch, agy can detect legacy Gemini CLI profiles and prompt you to choose which assets to migrate.
The migration flow can import extensions, global configuration, active session tokens, visual settings, workspace rules, skills, and MCP server definitions. Some customized terminal themes or experimental visual overlays may not have full parity.
Convert Gemini extensions to Antigravity plugins
Run:
agy plugin import geminiThe importer searches legacy local directories, reads extension manifests, and converts compatible files into Antigravity plugin layout blocks.
Context files
Antigravity CLI continues to read workspace context from:
GEMINI.md
AGENTS.mdIt also consults global developer context at:
~/.gemini/GEMINI.mdSkills path changes
| Scope | Path change |
|---|---|
| Global skills | ~/.gemini/skills/ to ~/.gemini/antigravity-cli/skills/ |
| Workspace skills | .gemini/skills/ to .agents/skills/ |
If a project has custom workspace skills in .gemini/skills/, move or rename that folder to .agents/skills/ so Antigravity can recognize those skills as active slash commands.
MCP config changes
Gemini CLI declared MCP servers inside:
~/.gemini/settings.jsonAntigravity CLI uses standalone MCP profiles:
~/.gemini/config/mcp_config.json
.agents/mcp_config.jsonFor remote websocket or SSE server definitions, update legacy url or httpUrl fields to serverUrl.
{
"mcpServers": {
"remote-indexer": {
"serverUrl": "https://mcp.internal.enterprise.com/sse",
"env": {
"AUTH_TOKEN": "secure_alpha_token"
}
}
}
}Example Workflows
Start work in a repository
cd path/to/project
agyIn the prompt, describe the task and scope. Keep the first request narrow. For example:
Review this repository and identify the files involved in the login flow. Do not edit files yet.Add another folder to the workspace
/add-dir ../shared-packageUse this when the agent needs access to a sibling package, shared library, or local dependency.
Run a terminal command
!npm testUse ! for commands you would normally run yourself. Keep review prompts enabled when a command can modify files, install dependencies, or reach the network.
Review changes before accepting them
/diffRead the diff before accepting a change. If the change is too broad, ask the agent to narrow the edit or explain the affected files.
Rewind a bad turn
/rewindUse /rewind or /undo when the conversation goes in the wrong direction. This rolls back conversation history to a previous message.
Fork an approach
/forkUse /fork when you want to explore a different solution without losing the current thread.
Resume earlier work
/resumeUse /resume to reopen previous conversation logs. Antigravity CLI also prints the command needed to resume a specific session when you close the CLI.
Use subagents without losing focus
/agentsOpen /agents when background work needs your approval or when you want to inspect what a subagent did. Use Ctrl+K for fast approval when a pending subagent action appears above the prompt.
Keep output quieter
/configSet verbosity to low if many tool calls make the terminal hard to scan.
Troubleshooting tips
| Problem | Fix |
|---|---|
agy not found | Check PATH and the install directory. |
| SSH sign-in stalls | Open the printed URL locally and paste the code. |
| Headless job waits or fails | Pass the prompt with -p and add required allow rules. |
| Invalid print-mode model | Choose one of the models listed in stderr. |
| Agent cannot see a folder | Use /add-dir <path> or start in project root. |
| Cannot find code | Use /codesearch; add -F for literal text. |
| Output is noisy | Lower verbosity or set AGY_CLI_CMD_OUTPUT_PERCENTAGE. |
| Command needs tighter safety | Use strict or enable sandboxing. |
| Workspace skill stopped working | Move .gemini/skills/ to .agents/skills/. |
| MCP config fails | Use mcp_config.json and serverUrl. |
| Need to inspect changes | Use /diff, then Ctrl+R. |
| Reset custom shortcuts | Delete keybindings.json. |
Related Resources
- Claude Code Commands Cheat Sheet
- OpenAI Codex Commands Cheat Sheet
- The Ultimate Claude Code Resource List
- 160+ Most Popular Agent Skills on GitHub for Coding Agents
- Gemini & Google AI Timeline: Gemini 3.5, Omni, and Nano Banana 2
FAQs
What command starts Antigravity CLI?
Run agy from your terminal.
What is the fastest way to see available commands?
Type / in the prompt box to open the slash command menu. Type ? for help or /usage for the offline developer manual.
How do I search the workspace from Antigravity CLI?
Run /codesearch, /cs, or /search. Searches use regular expressions by default. Add -F or --literal for an exact match.
How do I switch between default, accept-edits, and plan mode?
Press Shift+Tab, choose Agent Mode in /settings, or pass the mode with --mode when you start agy.
Where does Antigravity CLI store settings?
It stores main settings at ~/.gemini/antigravity-cli/settings.json and custom keybindings at ~/.gemini/antigravity-cli/keybindings.json.
How do I review code changes?
Use /diff to inspect modified files. Use Ctrl+R to open the Artifact Review Panel.
How do I undo a bad conversation turn?
Use /rewind or /undo to roll conversation history back to an earlier message.
How do I migrate from Gemini CLI?
Start agy in an environment that contains legacy Gemini CLI profiles and follow the first-launch checklist. To convert Gemini extensions manually, run agy plugin import gemini.
Does Antigravity CLI support MCP?
Yes. Use /mcp to open the MCP server manager. Global MCP servers use ~/.gemini/config/mcp_config.json, and workspace servers use .agents/mcp_config.json.
Should I use always-proceed?
Use always-proceed only in controlled workspaces where you are comfortable with the agent acting without prompts. For most coding work, request-review is safer.
How do I make Antigravity CLI quieter?
Open /config and set verbosity to low.





