
How to fix Agent execution terminated due to error in Antigravity?
You’re seeing “Agent execution terminated due to error.” in Antigravity on macOS, often right after you submit a prompt. Below is the fastest way to fix it, starting with the most effective steps.
How to fix Agent execution terminated due to error in Antigravity?
Many users report that Antigravity accepts a prompt, then instantly fails or hangs with the generic message: Agent execution terminated due to error. Switching models, restarting the app, or disabling MCP servers does not help. Logs often show API calls being rejected (401/403/429), pointing to stale auth, quota/account blocks, or backend instability.

If you’re an Ultra subscriber and it started suddenly, the most common culprits are: a bad auth session/token, a temporary backend outage, or network/proxy rules blocking Google AI endpoints.
Solution Overview
| Aspect | Detail |
|---|---|
| Root Cause | Stale/invalid auth tokens or API requests blocked/rejected (401/403/429), sometimes due to a backend incident or network filtering. |
| Primary Fix | Fully refresh Antigravity authentication and clear local caches/Keychain entries; then relaunch and sign in. |
| Complexity | Easy |
| Estimated Time | 10–20 minutes |
Read More: more ways to resolve the “agent terminated” error
How to fix Agent execution terminated due to error in Antigravity?
Step-by-Step Solution
- Check service health and account status (quick sanity checks)
- Verify Google service health: see the Google Cloud Status Dashboard for ongoing incidents that could affect Gemini/Gen AI endpoints.
- Confirm your subscription/account is active and in good standing (payment, usage limits).
- If available, try the same account at Google AI Studio to see if basic prompts respond. If Studio also fails, it’s likely an account or backend issue.
- Primary Fix: Hard-refresh Antigravity authentication on macOS
- Quit Antigravity completely.
- Right-click the dock icon > Quit, or:
- Terminal:
killall "Antigravity" 2>/dev/null || true- Clear potentially stale tokens in Keychain (safe search first):
- Terminal:
# List likely entries (review before deleting)
security find-generic-password -s "Antigravity" 2>/dev/null
security find-internet-password -s "generativelanguage.googleapis.com" 2>/dev/null
security find-internet-password -s "aistudio.google.com" 2>/dev/null- If you see stale entries tied to Antigravity or Gemini/AI Studio, delete them:
# Delete by service name (only if found above)
security delete-generic-password -s "Antigravity" 2>/dev/null || true
security delete-internet-password -s "generativelanguage.googleapis.com" 2>/dev/null || true
security delete-internet-password -s "aistudio.google.com" 2>/dev/null || true- You will sign in again on next launch.
- Clear local app caches and preferences (back up, then remove):
- Terminal:
# Create a backup folder on Desktop
mkdir -p "$HOME/Desktop/antigravity_backup"
# Move possible config/caches if they exist
[ -d "$HOME/Library/Application Support/Antigravity" ] && mv "$HOME/Library/Application Support/Antigravity" "$HOME/Desktop/antigravity_backup/" || true
[ -d "$HOME/Library/Caches/com.google.Antigravity" ] && mv "$HOME/Library/Caches/com.google.Antigravity" "$HOME/Desktop/antigravity_backup/" || true
# Remove stuck preferences (safe if key is present)
defaults delete com.google.Antigravity 2>/dev/null || true- Relaunch Antigravity and perform a fresh sign-in.
- Try a minimal prompt on a base model right away (e.g., “Say hello” on Gemini 1.5 Flash). If it works, the issue was stale auth.
- Network checks (rejects often trace to networking)
- Test reachability to Google AI endpoints (HTTP code may be 404/401; you only need a response to confirm reachability):
- Terminal:
curl -I https://generativelanguage.googleapis.com 2>/dev/null | head -n 1- Check for proxies that could block or rewrite TLS:
- Terminal:
env | grep -i proxy- If you see HTTP_PROXY/HTTPS_PROXY, temporarily unset them and retry:
unset HTTP_PROXY HTTPS_PROXY http_proxy https_proxy- If you’re on a corporate network, ask to allowlist:
- generativelanguage.googleapis.com
- aistudio.google.com
- ai.googleusercontent.com Then retry from the same machine. Alternatively, test from a mobile hotspot to bypass enterprise filtering.
- Reinstall Antigravity cleanly (if corruption is suspected)
- Remove the app and residuals, then reinstall the latest build.
- Terminal (remove app bundle if installed in Applications):
# Quit app first if running
killall "Antigravity" 2>/dev/null || true
# Remove app bundle (adjust if installed elsewhere)
rm -rf "/Applications/Antigravity.app"- Remove leftover support folders as in Step 2 (already done).
- Download a fresh installer from the official Antigravity page and reinstall.
- Launch, sign in, and test a trivial prompt.
- Confirm backend access with a direct API probe (optional but strong signal)
- Create or retrieve a Gemini API key at AI Studio API keys.
- Test a simple call (reachability and auth path check):
- Terminal:
export GEMINI_API_KEY="YOUR_KEY_HERE"
curl -s -o /dev/null -w "%{http_code}\n" \
"https://generativelanguage.googleapis.com/v1/models?key=${GEMINI_API_KEY}"- A 200 indicates your key works and networking is fine. If Antigravity still errors, the issue is app/session-specific.
- Read logs to verify “requests are being rejected”
- Terminal (macOS system logs for the past 30 minutes):
log show --predicate 'process CONTAINS[c] "Antigravity"' --last 30m | tail -n 200- Look for HTTP status codes like 401/403/429. These support the auth/quota root cause. If you contact support, attach this snippet.
Tip: If the issue persists across two different Google accounts on the same Mac and network, suspect a local network policy or a temporary service incident.
Related: troubleshooting “Fail to send” in Antigravity
Alternative Fixes & Workarounds
- Switch networks temporarily
- Try a personal hotspot or another Wi‑Fi to rule out corporate firewall/SSL inspection.
- Disable nonessential extensions/MCP servers
- You already disabled MCP; keep it off until a clean prompt succeeds.
- Use the web while you investigate
- Run your prompts in Google AI Studio as a temporary path to keep work moving.
- Use a smaller model first
- Start with Gemini 1.5 Flash or similar; larger models may hit stricter org-level quotas.
Deep-: handling token-limit stalls in Antigravity
Troubleshooting Tips
- Clock skew can break auth
- Ensure macOS Date & Time is set automatically.
- DNS issues
- Try switching to a public DNS (e.g., 8.8.8.8) in Network settings and re-test.
- VPN/Proxy
- Temporarily disconnect VPNs; re-test Antigravity.
- Model selection
- If a specific model is failing, test others to confirm if it’s model-scoped.
Best Practices
- Keep Antigravity updated; install new builds promptly.
- Sign out/in periodically if you switch between multiple Google accounts.
- Avoid running through SSL-intercepting proxies for AI tools.
- Keep only the MCP servers you actually need enabled.
Final Thought
Most “Agent execution terminated” cases are resolved by refreshing auth and clearing local caches. If logs still show rejected requests after that, it’s usually networking or a short-lived backend issue—check status, switch networks, or use the web interface as a stopgap.
Read More: a compact checklist for the Antigravity termination error
Subscribe to our newsletter
Get the latest updates and articles directly in your inbox.
Related Posts

How to fix 1024 tokens is not thinking error in Antigravity?
How to fix 1024 tokens is not thinking error in Antigravity?

How to fix Ultra dramatic quota reduction after update in Antigravity?
How to fix Ultra dramatic quota reduction after update in Antigravity?

How to fix Something unexpected happened and Stitch couldn't complete your generation error?
How to fix Something unexpected happened and Stitch couldn't complete your generation error?

