Getting Started with Gemini CLI

Start using Gemini CLI in seconds. No installation required.

1

Prerequisites

Make sure you have Node.js 18+ installed on your system.

2

Quickstart

The fastest way to use Gemini CLI is with npx:

npx https://github.com/google-gemini/gemini-cli

Or install globally with npm:

npm install -g @google/gemini-cligemini

Pick a color theme: When you first launch, you can choose your preferred color theme for the CLI interface.

3

Authentication

When prompted, sign in with your personal Google account. With Gemini 2.5 Pro, you get up to 60 model requests per minute and 1,000 model requests per day.

For advanced use or increased limits: If you need to use a specific model or require a higher request capacity, you can use an API key:

  1. Generate a key from Google AI Studio .
  2. Set it as an environment variable in your terminal (replace YOUR_API_KEY with your generated key):
export GEMINI_API_KEY="YOUR_API_KEY"

For other authentication methods, including Google Workspace accounts, see the authentication guide .

4

Example Usage

Start a project from a new directory:

cd new-project/gemini> Write me a Gemini Discord bot that answers questions using a FAQ.md file I will provide

Or work with an existing project:

git clone https://github.com/google-gemini/gemini-clicd gemini-cligemini> Give me a summary of all of the changes that went in yesterday

Once the CLI is running, you can interact with Gemini from your shell. Try generating code, automating tasks, and more. See the official examples for inspiration.

5

Next Steps