Enter the Prometheus data source URL

In this step, you’ll enter the Prometheus server URL. This URL is the address of the machine where Prometheus collects data.

In the Prometheus server URL field enter http://localhost:9090. Private data source connect (PDC) enables connection requests to resolve to this private address.

  • If your Prometheus server is local, use http://localhost:9090. If it’s on a server within a network, this is the URL with the port where you are running Prometheus. Example: http://prometheus.example.orgname:9090.

    Note

    If you’re running Grafana and Prometheus together in different container environments, each localhost refers to its own container - if the server URL is localhost:9090, that means port 9090 inside the Grafana container, not port 9090 on the host machine.

    You should use the IP address of the Prometheus container, or the hostname if you are using Docker Compose. Alternatively, you can consider http://host.docker.internal:9090.

  • If you aren’t using PDC, then you must enter a public IP or a fully qualified domain name for the address to resolve over the public network.

Did you know?

We recommend establishing a PDC connection. Without this secure connection, any queries and data exchanged between your on-premise data sources and Grafana Cloud occur over an insecure channel.

In the next step of your journey, you’ll configure basic security.

More to explore (optional)

At this point in your journey, you can explore the following paths:

Create a private connection to a data source