Docker CLI

docker network inspect

Returns network details. Narrow formatted output to the fields you need; membership is not proof of connectivity. The example requires the lab network from the custom networks lesson. Record the network ID and verify membership before removing a lab network.

Formal Syntax & Structure

docker syntaxdocker
docker network inspect [OPTIONS] NETWORK [NETWORK...]

Parameters & Attributes

NameTypeDescription
NETWORKstringNetwork name or ID.
--formatstringGo template selecting fields.

Working Example

Example Snippetdocker
docker network inspect --format '{{.Driver}} {{.Internal}}' bm-v05-custom-net
Docker Reference