Index
CLI
Learn how to use the Index browser agent through the command line interface
Command Line Interface
Index provides a convenient command line interface (CLI) that allows you to interact with the browser agent through your terminal.
Features
The Index CLI offers:
- Browser state persistence between sessions
- Follow-up messages with support for “give human control” action
- Real-time streaming updates
- Beautiful terminal UI using Textual
Getting Started with CLI
Prerequisites
Make sure you have Index installed:
Running the CLI
You can run the CLI with the following command:
Remember to set API key for the selected model in the .env
file.
Interactive Mode
When you run the CLI, you’ll enter interactive mode:
Model Selection
The CLI allows you to choose between different LLM models:
- Gemini 2.5 Pro (default) - Best for complex reasoning tasks that require fast execution
- Gemini 2.5 Flash - Good performance and fast execution, very cost effective
- Claude 3.7 Sonnet - Best for complex reasoning tasks
- OpenAI o4-mini - Good alternative with strong capabilities
Browser State Persistence
The CLI automatically maintains browser state between sessions, which means:
- Login sessions are preserved
- Cookies are maintained
- Site preferences are remembered
This makes it convenient for tasks that require authentication or maintaining context across multiple runs.
Stopping the Agent
You can exit the CLI at any time by pressing Ctrl+C
.