Containers usually need to talk — to the outside world, and to each other. Docker networking governs this: how a container reaches the internet, how you reach a container from your host, and how containers communicate among themselves. Understanding Docker's network types and how to use custom networks is essential for running anything beyond a single isolated container.
Docker provides several network drivers. The default bridge network connects containers on a host and uses NAT to reach the outside. The host network shares the host's network stack directly, removing isolation for raw performance. The none network disables networking. Most importantly, user-defined bridge networks add automatic DNS so containers can find each other by name — the standard for multi-container applications.
This lesson covers the bridge, host, and custom network types, how container-to-container communication and DNS work, and how port publishing connects containers to the host. These concepts are the foundation for Docker Compose and any application made of multiple communicating containers.