# Using host.docker.internal

I have a docker container that wants to use PostGresDB on the host machine in port 5432. How do I connect to the host PostGres server?

Answer: Use host.docker.internal in the connection string

```bash
POSTGRES_PRISMA_URL=postgresql://postgres:postgres@host.docker.internal/dbname
```

host.docker.internal works only with Mac or Windows, does not work in Linux!
