# Connect VPC and Subnets

Once the VPC and Subnet components have been added to the canvas and their properties are defined, it is now required to define the VPC properties for each of the subnets.

As the desired VPC doesn’t exist yet in our example, we will define the VPC property of each of the subnets by using connectors.

Each of the shapes on the canvas are shown with various dots on the edge of the shape, that represent the properties of the object. When you hover your mouse controls on the dots, the appropriate property representing dot is displayed on the canvas near the shape.

Connectors (Or lines or arrows) can be created by connecting the green and the red dots of shapes. By selecting the green dot on an object/shape and dragging to the appropriate red dot on the shape that is being connected, a connector is created. A connector connects the two objects and defines properties or dependencies.

In our case for connecting VPC and the Subnets, use the Mouse control to select the green dot on the VPC object and drag and connect to the red dot on the Subnet object.&#x20;

The following diagram depicts the red dot on the Subnet shape that corresponds to VPCID:

Diagram – Component shape and properties

<div align="left"><img src="/files/yYKVBpBDQsyzmivxf5ea" alt=""></div>

Using the mouse controls, select the green dot on the VPC object and draw a line to connect to the red dot on the subnet. This connector defines the VPCID property for the subnet.

&#x20;

Diagram – Connectors

<div align="left"><img src="/files/aIoiMEbUVETVaFdNbrbv" alt=""></div>

The following diagram depicts all the required connections to connect VPC and the two subnets.

Diagram – VPC and Subnets connected using connectors

<div align="left"><img src="/files/tbPs6AiVN8CMZzNwxlKi" alt=""></div>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.qmcloud.io/getting-started/connect-vpc-and-subnets.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
