# Run Antigravity CLI 24/7

> Antigravity CLI only works while its machine is awake and its session is open. An EnvHaven workspace is an always-on Linux machine with a persistent session and no prompts to stall it, so Antigravity CLI works through the night. The setup, and how to do the same on your own server.

_Updated November 23, 2026 · Checked against Antigravity CLI 1.4.7 in EnvHaven v1.9.0_

## What stops it

- **The machine sleeps.** Close a laptop and the agent stops with it.
- **The terminal closes.** Ending an SSH or terminal session sends a hangup to everything started in it.
- **A prompt waits for you.** An agent that asks before acting stops whenever you look away.
- **The provider pauses it.** Rate limits and outages stall a run until they pass.

## Run Antigravity CLI 24/7 on EnvHaven

A workspace answers the first two by design: it is a Linux machine that never sleeps, and its terminal session outlives every tab.

1. Open your workspace in any browser.
2. Tap **Launch**, choose Antigravity CLI and tap **Sign in**: it starts Antigravity CLI, which asks you to sign in the first time. For an API key, choose **Set key** instead and paste `GEMINI_API_KEY`; the workspace keeps it write-only.
3. Start it with one tap: signed in, Antigravity CLI gets a green dot in the Launch menu and an icon in the workspace's top bar. Support is built in (1.4.7), so there is nothing to install or update.
4. Give it a task. The image launches `agy` with `--dangerously-skip-permissions`, and sets the Gemini provider whenever a `GEMINI_API_KEY` is present.
5. Close the tab or the laptop. The workspace has no idle shutdown and its terminal session persists, so the work continues.
6. Open the workspace from any device, phone included, to read progress or answer a question.

## Keeping it from stalling

- Turn approval prompts off on the machine it runs on ([how, for Antigravity CLI](https://envhaven.com/yolo/antigravity-cli)).
- Watch its providers on the [Antigravity CLI status page](https://envhaven.com/status/antigravity-cli), and keep a second agent from another provider in the same workspace for the day one is down.
- Ask it to keep a progress file in the repository, so a fresh session can pick up where an old one stopped.

## On a server you manage yourself

Without a workspace you assemble the same things yourself: a Linux machine that never sleeps, Antigravity CLI installed and signed in without a browser, a session that survives disconnects, and no prompts. The [Antigravity CLI on a VPS](https://envhaven.com/agents/antigravity-cli/vps) page walks through it.

## Keep reading

- [Antigravity CLI](https://envhaven.com/agents/antigravity-cli)
- [Antigravity CLI in the browser](https://envhaven.com/agents/antigravity-cli/browser)
- [Antigravity CLI on iPhone](https://envhaven.com/agents/antigravity-cli/iphone)
- [Antigravity CLI on iPad](https://envhaven.com/agents/antigravity-cli/ipad)
- [Antigravity CLI full-access mode](https://envhaven.com/yolo/antigravity-cli)
- [Background coding agents](https://envhaven.com/guides/background-coding-agents)

Source: https://envhaven.com/agents/antigravity-cli/24-7
