Prometheus UI at localhost:9090/graph

1. The problem I’m having:

This might be a dumb question caused by my lack of knowledge about computers etc. However, I have Caddy running on a VPN (not my local computer) and I have Prometheus set up to scrape for metrics. I’m using Prometheus basically as an experiment, since Caddy is acting as a file server for my blog

The Caddy website says that I can view the Prometheus metrics at localhost:9090/graph

If you've started up a Prometheus server to scrape Caddy with the config above, try pasting these queries into the Prometheus UI at http://localhost:9090/graph

First dumb question: How can I access http://localhost:9090/graph in the browser when my website is hosted at

The Prometheus website also says I can use its tool at http://localhost:9090/graph.

If I had Caddy running on my home computer and Prometheus scraping metrics on my home computer, then I understand how to open local host, but not when I’m on a VPN and using a custom domain.

When I go to http://localhost:9090/graph, it says the site can’t be reached, as I’d expect it to say.

2. Error messages and/or full log output:

Please use the preview pane to ensure it looks nice.

3. Caddy version:


4. How I installed and ran Caddy:

via the instructions on the Caddy website for ubuntu

a. System environment:


b. Command:

Please use the preview pane to ensure it looks nice.

c. Service/unit/compose file:

Please use the preview pane to ensure it looks nice.

d. My complete Caddy config:

Please use the preview pane to ensure it looks nice.

5. Links to relevant resources:

You could set up an SSH tunnel to your server, which would let you access resources on the other machine as if it was on your own machine. Basically it’ll bind a port on your local machine to get routed through SSH to your server, and then you can hit localhost:9090 as if it was on your local machine. Google it.

Or you could have Caddy proxy to your Prometheus instance to serve it (as long as it has authentication – I don’t know if it does, I don’t use Prometheus myself). Probably on a subdomain.

You could use Grafana Cloud instead of Prometheus if you prefer (free account), which would let you see your metrics from anywhere. It’s basically cloud-hosted Prometheus.

Thank you @francislavoie .

It seems like the localhost:2019/metrics route is specifically designed to be scraped by Prometheus. If you don’t use Prometheus yourself, do you know of another app that is suited for collecting metrics from localhost:2019/metrics, or do you just not bother with monitoring at all?

I also looked at the localhost:2019/debug/vars endpoint (which serves some metrics in the widely used json format) but it doesn’t contain a lot of the metrics that are available at localhost:2019/metrics. Are there any plans by Caddy team to make the same metrics available at both endpoints? That way we won’t have to rely on Prometheus to scrape 2019/metrics unless of course there’s another app that does it.

It’s for any OpenTelemetry compatible application. Prometheus popularized the format and it became a standard.

I don’t play with monitoring, personally.


Unfortunately the metrics functionality was contributed by someone who no longer has time to help maintain it, and the rest of the core team doesn’t have any expertise with this stuff, so we’re not equipped to make any improvements.

We need help from someone more experienced with metrics to fix some of the problems and add new features.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.