<a id="space"></a>

# Space

See also: [How to manage spaces](https://documentation.ubuntu.com/juju/4.0/howto/manage-spaces.md#manage-spaces)

A Juju **(network) space** is a logical grouping of [subnets](https://documentation.ubuntu.com/juju/4.0/reference/subnet.md#subnet) that can communicate with one another.

A space is used to help segment network traffic for the purpose of:

* Network performance
* Security
* Controlling the scope of regulatory compliance

## Spaces as constraints and bindings

Spaces can be specified as [constraints](https://documentation.ubuntu.com/juju/4.0/reference/constraint.md#constraint) – to determine what subnets a machine is connected to – or as application endpoint bindings – to determine the subnets used by application relations.

A binding associates an [application endpoint](https://documentation.ubuntu.com/juju/4.0/reference/application.md#application-endpoint) with a space. This restricts traffic for the endpoint to the subnets in the space. By default, endpoints are bound to the space specified in the `default-space` model configuration value. The name of the default space is “alpha”.

Constraints and bindings affect application deployment and machine provisioning as well as the subnets a machine can talk to.

Endpoint bindings can be specified during deployment with `juju deploy --bind` or changed after deployment using the `juju bind` command.

## Support for spaces in Juju providers

Support for spaces may vary from one cloud to another. For cloud-specific details, see the networking behavior section in each cloud’s reference doc: [Amazon EC2](https://documentation.ubuntu.com/juju/4.0/reference/cloud/list-of-supported-clouds/amazon-ec2.md#cloud-ec2), [Microsoft Azure](https://documentation.ubuntu.com/juju/4.0/reference/cloud/list-of-supported-clouds/microsoft-azure.md#cloud-azure), [OpenStack](https://documentation.ubuntu.com/juju/4.0/reference/cloud/list-of-supported-clouds/openstack.md#cloud-openstack), [LXD](https://documentation.ubuntu.com/juju/4.0/reference/cloud/list-of-supported-clouds/lxd.md#cloud-lxd), [MAAS](https://documentation.ubuntu.com/juju/4.0/reference/cloud/list-of-supported-clouds/maas.md#cloud-maas), [Unmanaged](https://documentation.ubuntu.com/juju/4.0/reference/cloud/list-of-supported-clouds/unmanaged.md#cloud-unmanaged).
