Path

Enter the query URL for your Loki backend using the format that matches your environment.

Estimated time: 2 min

Configure the connection URL

The connection URL tells Grafana where to send log queries. The format depends on your Loki environment.

Use the URL format that matches your backend:

EnvironmentURL formatExample
Self-managed Lokihttp://<host>:3100http://loki:3100
Grafana Cloud LogsCopy from the Cloud Portalhttps://logs-prod-006.grafana.net
Grafana Enterprise LogsURL of your GEL gatewayhttps://gel.example.com

For Grafana Cloud Logs, copy the exact query URL from the Loki details page in the Cloud Portal — don’t assume the https://logs-prod-<zone>.grafana.net pattern, since some stacks use nested or legacy hostnames. https://logs-prod-006.grafana.net is one example.

To configure the connection URL, complete the following step:

  1. In the URL field under the Connection section, enter the query URL for your Loki backend.

    For example, for Grafana Cloud Logs, enter a URL like https://logs-prod-006.grafana.net. For self-managed Loki, enter a URL like http://loki:3100.

    Tip: Enter only the base URL. Don’t append API paths such as /loki/api/v1/push — that endpoint is for sending logs to Loki (with an agent like Grafana Alloy), not for querying, and appending it is a common cause of a failed Save & test. To send logs to Loki, refer to Send log data to Loki.

In the next milestone, you configure authentication for the connection.


More to explore (optional)