---
title: "Introduction to the Grafana CLI tools | Grafana documentation"
description: "Overview of Grafana CLI, a command line tool for managing Grafana resources as code."
---

> For a curated documentation index, see [llms.txt](/llms.txt). For the complete documentation index, see [llms-full.txt](/llms-full.txt).

# Introduction to the Grafana CLI tools

Grafana command-line tools are designed to simplify interaction with Grafana instances. You can authenticate, manage multiple environments, and perform administrative tasks through the Grafana REST API, all from the terminal. Whether you’re automating workflows in CI/CD pipelines or switching between staging and production environments, the Grafana CLI tools provide a flexible and efficient way to manage your Grafana setup as code.

`gcx` works across all environments for Grafana OSS, Enterprise, and Cloud. **Use `gcx` to work with AI agents**.

## Explore

[gcx  
\
Learn how to use gcx, the Grafana CLI compatible with AI agents](https://grafana.com/docs/grafana/next/ai-tools/grafana-cli/gcx)

[grafanactl CLI (deprecated)  
\
Learn how to install, set up and use the Grafana CLI `grafanactl`](https://grafana.com/docs/grafana/next/ai-tools/grafana-cli/grafanactl)
