# Prometheus Authentication

**URL:** <https://discuss.prometheus.io/t/prometheus-authentication/3265>\
**Category:** Prometheus server\
**Created:** [January 23, 2025, 11:36am UTC](https://discuss.prometheus.io/t/prometheus-authentication/3265 "2025-01-23T11:36:15Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![acosta353](https://dub1.discourse-cdn.com/flex017/user_avatar/discuss.prometheus.io/acosta353/32/1108_2.png) [@acosta353](https://discuss.prometheus.io/u/acosta353)\
**Post date:** [January 23, 2025, 11:36am UTC](https://discuss.prometheus.io/t/prometheus-authentication/3265/1 "2025-01-23T11:36:15Z")

</div>

Hello,

I’m running prometheus from the “prom/prometheus” docker image using the docker run command, and i would like to know how, and if it is possible, to configure the basic authentication so Prometheus won’t be open to all web.

I tried to pass the argument “-v /etc/prometheus/web-config.yml:/etc/prometheus/web-config.yml” in the command, and also “–web.config.file=/etc/prometheus/web-config.yml” but without success.

Can someone help?
