Google moved individual Gemini CLI users to Antigravity CLI on June 18, 2026. Antigravity loads AGENTS.md or GEMINI.md (plus .agents/rules/*.md) per directory and global rules from ~/.gemini/AGENTS.md or ~/.gemini/GEMINI.md. Its MCP servers live in ~/.gemini/config/mcp_config.json or .agents/mcp_config.json, and permissions are Deny / Ask / Allow lists on top of a Default, Request Review or Turbo preset. Gemini CLI uses ~/.gemini/settings.json / .gemini/settings.json (mcpServers, context.fileName) plus policy TOML files, and reads only GEMINI.md unless you set context.fileName. Sign in with a Google account (Google AI Pro/Ultra included) or use a Gemini API key.
Antigravity / Gemini CLI at a glance
| Global instructions | ✓ Yes Antigravity: ~/.gemini/AGENTS.md, ~/.gemini/GEMINI.md, ~/.gemini/config/AGENTS.md. Gemini CLI: ~/.gemini/GEMINI.md |
|---|---|
| Project instructions | ✓ Yes Antigravity: AGENTS.md / GEMINI.md, .agents/AGENTS.md, .agents/rules/*.md. Gemini CLI: GEMINI.md in workspace dirs and parents |
| Nested / subfolder | ✓ Yes Directory-scoped rules at each level; Gemini CLI loads GEMINI.md just-in-time when a tool touches a directory |
| AGENTS.md | ◐ Partial Antigravity: yes, native. Gemini CLI: only via context.fileName (e.g. ["AGENTS.md", "GEMINI.md"]) |
| Skills (SKILL.md) | ✓ Yes.agents/skills/ (workspace), ~/.gemini/config/skills/ (Antigravity), ~/.gemini/antigravity-cli/skills/ (CLI); Gemini CLI: .gemini/skills/ or .agents/skills/, ~/.gemini/skills/ |
| MCP config | ✓ Yes Antigravity: ~/.gemini/config/mcp_config.json, .agents/mcp_config.json. Gemini CLI: mcpServers in ~/.gemini/settings.json or .gemini/settings.json |
| Permissions / allowlist | ✓ Yes Antigravity: Deny > Ask > Allow rules ( command(), read_file(), write_file(), read_url(), mcp()) over a Default / Request Review / Turbo preset. Gemini CLI: policy engine TOML in ~/.gemini/policies/ (allow / deny / ask_user) |
| Sandbox | ✓ Yes Antigravity terminal sandbox on under the Default preset (workspace + temp only, no network). Gemini CLI: --sandbox / -s (Docker, Podman or macOS Seatbelt) |
| Hooks | ✓ Yes Antigravity: .agents/hooks.json, ~/.gemini/config/hooks.json. Gemini CLI: hooks in settings.json |
| Claude Pro/Max login | ✕ No Not supported |
| ChatGPT Plus/Pro login | ✕ No Not supported |
| API key / own plan | ✓ Yes Google account sign-in (free, Google AI Pro/Ultra, enterprise) or a Gemini API key; Vertex AI for Gemini CLI |
Exact file paths
| Path | Scope | What it does |
|---|---|---|
AGENTS.md / GEMINI.md | Workspace dirs | Antigravity context files (Gemini CLI: GEMINI.md by default) |
.agents/rules/*.md | Workspace | Antigravity modular rules (flat folder) |
~/.gemini/GEMINI.md / ~/.gemini/AGENTS.md | User | Global rules |
~/.gemini/config/mcp_config.json | User | Antigravity MCP servers |
.agents/mcp_config.json | Workspace | Antigravity project MCP servers |
~/.gemini/settings.json / .gemini/settings.json | User / project | Gemini CLI settings: mcpServers, context, tools, hooks |
~/.gemini/policies/*.toml | User | Gemini CLI policy-engine rules |
.agents/hooks.json | Workspace | Antigravity hooks |
.agents/skills/<name>/SKILL.md | Workspace | Skills for both tools |
Using a shared AGENTS.md with Antigravity / Gemini CLI
Antigravity: native. Gemini CLI: set context.fileName to ["AGENTS.md", "GEMINI.md"] in .gemini/settings.json (or symlink GEMINI.md). See one AGENTS.md for every agent, or generate one with the AGENTS.md generator.
Copy-paste examples
Make Gemini CLI read AGENTS.md
File: .gemini/settings.json
{
"context": {
"fileName": ["AGENTS.md", "GEMINI.md"]
}
}
Antigravity workspace MCP server
File: .agents/mcp_config.json
{
"mcpServers": {
"context7": {
"command": "npx",
"args": ["-y", "@upstash/context7-mcp"]
}
}
}
Gemini CLI policy: deny rm -rf
File: ~/.gemini/policies/safety.toml
[[rule]]
toolName = "run_shell_command"
commandPrefix = "rm -rf"
decision = "deny"
priority = 100
[[rule]]
toolName = "run_shell_command"
commandPrefix = "git push"
decision = "ask_user"
priority = 100
Safe permissions preset
Safe Antigravity permissions (Deny / Ask lists)
File: Settings → Permissions
Preset: Default (terminal sandbox on, workspace + temp dirs only, no network)
Deny:
command(rm -rf)
command(sudo)
command(git push --force)
command(git push -f)
command(git reset --hard)
command(terraform destroy)
read_file(~/.ssh)
read_file(~/.aws)
write_file(.env)
Ask:
command(git push)
command(kubectl)
command(psql)
command(mysql)
Antigravity evaluates Deny > Ask > Allow and matches commands by literal token prefix (or regex: per token), so a SQL statement inside psql -c can't be matched; put database clients in Ask instead. Turbo disables the sandbox and allows everything. The docs don't name the file these lists are stored in, so set them in Settings.
Gotchas
- Gemini CLI stopped serving free, Google AI Pro and Ultra individual users on June 18, 2026; they were moved to Antigravity CLI. API-key, Vertex and enterprise users can still run Gemini CLI.
- Gemini CLI ignores AGENTS.md unless
context.fileNamelists it; Antigravity reads it natively. - Antigravity only scans the immediate
.mdchildren of.agents/rules/. - Antigravity's Turbo preset turns the sandbox off and allows commands without prompting.
- Command substitution such as
$(...)or backticks can hide a command behind a harmless prefix; Antigravity treats those constructs specially, but keep destructive tools in Deny.
FAQ
Does Gemini CLI read AGENTS.md?
Where is the MCP config for Antigravity?
Where is GEMINI.md loaded from?
Can I use Google AI Pro with Gemini CLI or Antigravity?
Sources
Checked against these official pages on 2026-10-12. Cells marked "Not documented" mean we could not find the behaviour in these docs; it may still exist.