# List networks


[API catalog](/reference/api/) · [Docker Engine overview](/reference/api/engine/version/v1.57/) · [Product manual](https://docs.docker.com/engine/) · [OpenAPI specification](/reference/api/engine/version/v1.57.yaml)

API version: 1.57





`GET /networks`

Returns a list of networks. For details on the format, see the
[network inspect endpoint](/reference/api/engine/version/v1.57/operations/NetworkInspect/).

Note that it uses a different, smaller representation of a network than
inspecting a single network. For example, the list of containers attached
to the network is not propagated in API versions 1.28 and up.


## Connection and access

[API connection and authentication guidance](/reference/api/engine/version/v1.57/#connection)


Server: `/v1.57`

Effective security: alternatives are OR; schemes within an alternative are AND. An empty array declares no HTTP authentication requirement.

```json
null
```

## Example request

Replace placeholders and provide the required credentials or request body.

```console
curl \
  --request GET \
  --unix-socket "${DOCKER_SOCKET:-/var/run/docker.sock}" \
  --header 'Accept: application/json' \
  'http://localhost/v1.57/networks'
```



## Parameters

### filters

Location: query. Required: no.

JSON encoded value of the filters (a `map[string][]string`) to process
on the networks list.

Available filters:

- `dangling=<boolean>` When set to `true` (or `1`), returns all
   networks that are not in use by a container. When set to `false`
   (or `0`), only networks that are in use by one or more
   containers are returned.
- `driver=<driver-name>` Matches a network's driver.
- `id=<network-id>` Matches all or part of a network ID.
- `label=<key>` or `label=<key>=<value>` of a network label.
- `name=<network-name>` Matches all or part of a network name.
- `scope=["swarm"|"global"|"local"]` Filters networks by scope (`swarm`, `global`, or `local`).
- `type=["custom"|"builtin"]` Filters networks by type. The `custom` keyword returns all user-defined networks.


```json
{
  "description": "JSON encoded value of the filters (a `map[string][]string`) to process\non the networks list.\n\nAvailable filters:\n\n- `dangling=\u003cboolean\u003e` When set to `true` (or `1`), returns all\n   networks that are not in use by a container. When set to `false`\n   (or `0`), only networks that are in use by one or more\n   containers are returned.\n- `driver=\u003cdriver-name\u003e` Matches a network's driver.\n- `id=\u003cnetwork-id\u003e` Matches all or part of a network ID.\n- `label=\u003ckey\u003e` or `label=\u003ckey\u003e=\u003cvalue\u003e` of a network label.\n- `name=\u003cnetwork-name\u003e` Matches all or part of a network name.\n- `scope=[\"swarm\"|\"global\"|\"local\"]` Filters networks by scope (`swarm`, `global`, or `local`).\n- `type=[\"custom\"|\"builtin\"]` Filters networks by type. The `custom` keyword returns all user-defined networks.\n",
  "in": "query",
  "name": "filters",
  "pointer": "/paths/~1networks/get/parameters/0",
  "schema": {
    "type": "string"
  }
}
```

## Request and responses

### Response 200 application/json

No error


Schema:

```json
{
  "items": {
    "$ref": "#/components/schemas/NetworkSummary"
  },
  "type": "array"
}
```









Example:
```json
[
  {
    "Attachable": false,
    "Created": "2016-10-19T06:21:00.416543526Z",
    "Driver": "bridge",
    "EnableIPv4": true,
    "EnableIPv6": false,
    "IPAM": {
      "Config": [
        {
          "Subnet": "172.17.0.0/16"
        }
      ],
      "Driver": "default"
    },
    "Id": "f2de39df4171b0dc801e8002d1d999b77256983dfc63041c0f34030aa3977566",
    "Ingress": false,
    "Internal": false,
    "Name": "bridge",
    "Options": {
      "com.docker.network.bridge.default_bridge": "true",
      "com.docker.network.bridge.enable_icc": "true",
      "com.docker.network.bridge.enable_ip_masquerade": "true",
      "com.docker.network.bridge.host_binding_ipv4": "0.0.0.0",
      "com.docker.network.bridge.name": "docker0",
      "com.docker.network.driver.mtu": "1500"
    },
    "Scope": "local"
  },
  {
    "Attachable": false,
    "Containers": {},
    "Created": "0001-01-01T00:00:00Z",
    "Driver": "null",
    "EnableIPv4": false,
    "EnableIPv6": false,
    "IPAM": {
      "Config": [],
      "Driver": "default"
    },
    "Id": "e086a3893b05ab69242d3c44e49483a3bbbd3a26b46baa8f61ab797c1088d794",
    "Ingress": false,
    "Internal": false,
    "Name": "none",
    "Options": {},
    "Scope": "local"
  },
  {
    "Attachable": false,
    "Containers": {},
    "Created": "0001-01-01T00:00:00Z",
    "Driver": "host",
    "EnableIPv4": false,
    "EnableIPv6": false,
    "IPAM": {
      "Config": [],
      "Driver": "default"
    },
    "Id": "13e871235c677f196c4e1ecebb9dc733b9b2d2ab589e30c539efeda84a24215e",
    "Ingress": false,
    "Internal": false,
    "Name": "host",
    "Options": {},
    "Scope": "local"
  }
]
```


### Response 500 application/json

Server error


Schema:

```json
{
  "$ref": "#/components/schemas/ErrorResponse"
}
```









Schema example:
```json
{
  "message": "Something went wrong."
}
```


## Complete operation contract

```json
{
  "description": "Returns a list of networks. For details on the format, see the\n[network inspect endpoint](#operation/NetworkInspect).\n\nNote that it uses a different, smaller representation of a network than\ninspecting a single network. For example, the list of containers attached\nto the network is not propagated in API versions 1.28 and up.\n",
  "operationId": "NetworkList",
  "parameters": [
    {
      "description": "JSON encoded value of the filters (a `map[string][]string`) to process\non the networks list.\n\nAvailable filters:\n\n- `dangling=\u003cboolean\u003e` When set to `true` (or `1`), returns all\n   networks that are not in use by a container. When set to `false`\n   (or `0`), only networks that are in use by one or more\n   containers are returned.\n- `driver=\u003cdriver-name\u003e` Matches a network's driver.\n- `id=\u003cnetwork-id\u003e` Matches all or part of a network ID.\n- `label=\u003ckey\u003e` or `label=\u003ckey\u003e=\u003cvalue\u003e` of a network label.\n- `name=\u003cnetwork-name\u003e` Matches all or part of a network name.\n- `scope=[\"swarm\"|\"global\"|\"local\"]` Filters networks by scope (`swarm`, `global`, or `local`).\n- `type=[\"custom\"|\"builtin\"]` Filters networks by type. The `custom` keyword returns all user-defined networks.\n",
      "in": "query",
      "name": "filters",
      "schema": {
        "type": "string"
      }
    }
  ],
  "responses": {
    "200": {
      "content": {
        "application/json": {
          "example": [
            {
              "Attachable": false,
              "Created": "2016-10-19T06:21:00.416543526Z",
              "Driver": "bridge",
              "EnableIPv4": true,
              "EnableIPv6": false,
              "IPAM": {
                "Config": [
                  {
                    "Subnet": "172.17.0.0/16"
                  }
                ],
                "Driver": "default"
              },
              "Id": "f2de39df4171b0dc801e8002d1d999b77256983dfc63041c0f34030aa3977566",
              "Ingress": false,
              "Internal": false,
              "Name": "bridge",
              "Options": {
                "com.docker.network.bridge.default_bridge": "true",
                "com.docker.network.bridge.enable_icc": "true",
                "com.docker.network.bridge.enable_ip_masquerade": "true",
                "com.docker.network.bridge.host_binding_ipv4": "0.0.0.0",
                "com.docker.network.bridge.name": "docker0",
                "com.docker.network.driver.mtu": "1500"
              },
              "Scope": "local"
            },
            {
              "Attachable": false,
              "Containers": {},
              "Created": "0001-01-01T00:00:00Z",
              "Driver": "null",
              "EnableIPv4": false,
              "EnableIPv6": false,
              "IPAM": {
                "Config": [],
                "Driver": "default"
              },
              "Id": "e086a3893b05ab69242d3c44e49483a3bbbd3a26b46baa8f61ab797c1088d794",
              "Ingress": false,
              "Internal": false,
              "Name": "none",
              "Options": {},
              "Scope": "local"
            },
            {
              "Attachable": false,
              "Containers": {},
              "Created": "0001-01-01T00:00:00Z",
              "Driver": "host",
              "EnableIPv4": false,
              "EnableIPv6": false,
              "IPAM": {
                "Config": [],
                "Driver": "default"
              },
              "Id": "13e871235c677f196c4e1ecebb9dc733b9b2d2ab589e30c539efeda84a24215e",
              "Ingress": false,
              "Internal": false,
              "Name": "host",
              "Options": {},
              "Scope": "local"
            }
          ],
          "schema": {
            "items": {
              "$ref": "#/components/schemas/NetworkSummary"
            },
            "type": "array"
          }
        }
      },
      "description": "No error"
    },
    "500": {
      "content": {
        "application/json": {
          "schema": {
            "$ref": "#/components/schemas/ErrorResponse"
          }
        }
      },
      "description": "Server error"
    }
  },
  "summary": "List networks",
  "tags": [
    "Network"
  ]
}
```

## Referenced schemas

- [#/components/schemas/ErrorResponse](/reference/api/engine/version/v1.57/schemas/ErrorResponse/)

- [#/components/schemas/NetworkSummary](/reference/api/engine/version/v1.57/schemas/NetworkSummary/)




