---
title: "Verify Elasticsearch is accessible | Grafana Labs"
description: "Confirm that your Elasticsearch instance is running and gather the details needed to connect from Grafana."
---

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

# Verify Elasticsearch is accessible

Before you connect Grafana to Elasticsearch, confirm that your Elasticsearch instance is running and that you have the information Grafana needs to establish a connection.

### Gather connection details

Collect the following values before proceeding:

Expand table

| Detail              | Required                      | Example                                 |
|---------------------|-------------------------------|-----------------------------------------|
| **URL**             | Yes                           | `http://elasticsearch.example.com:9200` |
| **Index name**      | Recommended                   | `logs-*` or `[filebeat-]YYYY.MM.DD`     |
| **Time field name** | No (defaults to `@timestamp`) | `@timestamp`                            |
| **Authentication**  | Depends on your setup         | Username and password, or API key       |

The URL is the only required connection value. **Index name** and **Time field name** are optional Elasticsearch details — Grafana defaults the time field to `@timestamp` — but setting them makes querying easier. The Elasticsearch data source supports v7.17 or later, v8.x, v9.x, and Elastic Cloud Serverless.

### Verify connectivity

Confirm Elasticsearch is reachable by running this command from your terminal:

Bash ![Copy code to clipboard](/media/images/icons/icon-copy-small-2.svg) Copy

```bash
curl -s -o /dev/null -w "%{http_code}" http://YOUR_ELASTICSEARCH_HOST:9200
```

A `200` response confirms that Elasticsearch is accepting connections. If your instance requires authentication, add credentials with `-u username:password` or an API key header.

**If Elasticsearch is behind a firewall:** You’ll need [Private data source connect (PDC)](/docs/grafana-cloud/connect-externally-hosted/private-data-source-connect/) to allow Grafana Cloud to reach it. Set up PDC before continuing.

### Confirm read permissions

When Elasticsearch security features are enabled, the user or API key that Grafana connects with needs the following cluster privileges:

- **monitor** — Retrieves version information for the connected Elasticsearch instance.
- **view\_index\_metadata** — Accesses the mapping definitions of indices.
- **read** — Performs search and retrieval operations on indices.

**Security tip:** Scope the credentials to the minimum privileges Grafana needs — read access to the indices you want to query. Refer to [Configure the Elasticsearch data source](/docs/grafana/latest/datasources/elasticsearch/configure/) for details.

In the next milestone, you’ll add Elasticsearch as a data source in Grafana Cloud.
