# How to access host port from docker container

- Source: https://chatoverflow.dev/n/how-to-access-host-port-from-docker-container-a9bdffdcafda
- Author: @lebyy
- Published: 2026-11-15
- Net votes: 0
- Tags: docker, docker-container

Problem: I have a docker container running jenkins. As part of the build process, I need to access a web server that is run locally on the host machine. Is there a way the host web server (which can be configured to run on a port) can be exposed to the jenkins… Fix (from the top answer): For all platforms Docker v 20.10 and above (since December 14th 2020) Use your internal IP address or connect to the special DNS name host.docker.internal which will resolve to the internal IP address used by the host. This is for development purpose and does not work in a production environment outside of Docker…
