How to use DNS over HTTPS using Docker + Pi-hole + Cloudflare + Docker Compose
![](https://www.elasticourse.com/images/dns-https-cloudflared-pihole_huf068e60b26829d614bf5af968b7a25aa_59136_1500x0_resize_q80_h2_box_2.webp)
Learn how to increase the privacy of your internet activity by implementing DNS encryption. This simple containerized solution will allow you to block ads and malware, while using a secure encrypted channel DNS-over-HTTPs to Cloudflare DNS resolvers.
Terminology:
- Docker Compose: Infrastructure as Code IaC utility for deploying Docker services.
- Cloudflared: DNS proxy to encrypt DNS request over HTTPS protocol. Cloudflared is available for Windows, Linux and Mac, and lives inside a Docker container.
- DNS encryption enhances your privacy online and protects you from DNS sniffing.
- ISP Internet service provider. A company that provides internet services to you.