Yandex Cloud
Search
Contact UsGet started
  • Blog
  • Pricing
  • Documentation
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • ML & AI
    • Business tools
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Customer Stories
    • Gateway to Russia
    • Cloud for Startups
    • Education and Science
  • Blog
  • Pricing
  • Documentation
Yandex project
© 2025 Yandex.Cloud LLC
Yandex Virtual Private Cloud
  • Getting started
    • All guides
      • Creating a cloud network
      • Deleting a cloud network
      • Updating a cloud network
      • Getting information about a cloud network
      • Viewing a cloud network map
      • Moving a cloud network between folders
    • Enabling a software-accelerated network
    • Chart of network connections
    • Viewing operations with resources
  • DDoS Protection
  • Access management
  • Terraform reference
  • Audit Trails events
  • Release notes
  • FAQ
  1. Step-by-step guides
  2. Cloud network
  3. Creating a cloud network

Creating a cloud network

Written by
Yandex Cloud
Improved by
Danila N.
Updated at May 5, 2025

In addition to the cloud network in the default folder, you can create cloud networks in other folders.

Management console
CLI
Terraform
API

To create a cloud network:

  1. In the management console, go to the folder where you need to create a cloud network.

  2. In the list of services, select Virtual Private Cloud.

  3. In the top-right corner, click Create network.

  4. In the Name field, enter a name for the network. The naming requirements are as follows:

    • It must be from 2 to 63 characters long.
    • It may contain lowercase Latin letters, numbers, and hyphens.
    • It must start with a letter and cannot end with a hyphen.
  5. (Optional) In the Description field, add a network description.

  6. The default option is Create subnets. If you want to create subnets later, disable this option.

  7. Click Create network.

If you do not have the Yandex Cloud CLI yet, install and initialize it.

The folder specified when creating the CLI profile is used by default. To change the default folder, use the yc config set folder-id <folder_ID> command. You can specify a different folder using the --folder-name or --folder-id parameter.

To create a cloud network:

  1. View the description of the CLI command for creating a cloud network:

    yc vpc network create --help
    
  2. Create a cloud network in the default folder:

    yc vpc network create \
      --name test-network-1 \
      --description "My test network"
    

    The --name and --description flags are optional: you can create a network without any name and description and access it by ID.

    The network naming requirements are as follows:

    • It must be from 2 to 63 characters long.
    • It may contain lowercase Latin letters, numbers, and hyphens.
    • It must start with a letter and cannot end with a hyphen.
  3. Get a list of all cloud networks in the default folder:

    yc vpc network list
    

    Result:

    +----------------------+----------------+
    |          ID          |      NAME      |
    +----------------------+----------------+
    | enpiuvhhd4t8******** | test-network-1 |
    | enplom7a98s1******** | default        |
    +----------------------+----------------+
    

    Get the same list with more details in YAML format:

    yc vpc network list --format yaml
    

    Result:

    - id: enpiuvhhd4t8********
      folder_id: b1g6ci08ma55********
      created_at: "2018-10-23T11:12:51Z"
      name: test-network-1
      description: My first network
    - id: enplom7a98s1********
      folder_id: b1g6ci08ma55********
      created_at: "2018-09-24T08:23:00Z"
      name: default
      description: Auto-created default network
    

With Terraform, you can quickly create a cloud infrastructure in Yandex Cloud and manage it using configuration files. These files store the infrastructure description written in HashiCorp Configuration Language (HCL). If you change the configuration files, Terraform automatically detects which part of your configuration is already deployed, and what should be added or removed.

Terraform is distributed under the Business Source License. The Yandex Cloud provider for Terraform is distributed under the MPL-2.0 license.

For more information about the provider resources, see the documentation on the Terraform website or mirror website.

If you do not have Terraform yet, install it and configure its Yandex Cloud provider.

  1. In the configuration file, describe the parameters of your cloud network:

    • name: Name of the cloud network. The naming requirements are as follows:

      • It must be from 2 to 63 characters long.
      • It may contain lowercase Latin letters, numbers, and hyphens.
      • It must start with a letter and cannot end with a hyphen.
    • description: Cloud network description.

    • labels: Cloud network labels. Specify a key-value pair.

    Here is an example of the configuration file structure:

    resource "yandex_vpc_network" "default" {
      name        = "<network_name>"
      description = "<network_description>"
      labels = {
        tf-label    = "tf-label-value"
        empty-label = ""
      }
    }
    

    For more information about the vpc_network resource parameters in Terraform, see the relevant provider documentation.

  2. Make sure the configuration files are correct.

    1. In the command line, go to the directory where you created the configuration file.

    2. Run a check using this command:

      terraform plan
      

    If the configuration description is correct, the terminal will display a list of the resources being created and their parameters. If the configuration contains any errors, Terraform will point them out.

  3. Deploy the cloud resources.

    1. If the configuration does not contain any errors, run this command:

      terraform apply
      
    2. Confirm creating the resources: type yes in the terminal and press Enter.

      This will create all the resources you need in the specified folder. You can check the new resources and their settings using the management console or these CLI commands:

      yc vpc network list
      

To create a cloud network, use the create REST API method for the Network resource or the NetworkService/Create gRPC API call, and provide the following in the request:

  • ID of the folder the network will reside in, in the folderId parameter.
  • Name of the new network in the name parameter. The name must be 3 to 63 characters long, the last character cannot be a hyphen.
  • New network description in the description parameter. The description may be up to 256 characters long.

The name and description parameters are optional: you can create a network without any name and description and access it by ID.

To learn how to find out the folder ID, see Getting the folder ID.

ExamplesExamples

Create a cloud network with a name and description in the selected folder:

CLI
Terraform
yc vpc network create --name test-network-1 \
  --description "My test network" \
  --folder-id b1gnbfd11bq5********
  1. In the configuration file, describe the parameters of the cloud network to create:

    resource "yandex_vpc_network" "default" {
      name        = "network-1"
      description = "My first network"
    }
    

    For more information about resource parameters in Terraform, see the relevant provider documentation.

  2. Make sure the configuration files are correct.

    1. In the command line, go to the directory where you created the configuration file.

    2. Run a check using this command:

      terraform plan
      

    If the configuration description is correct, the terminal will display a list of the resources being created and their parameters. If the configuration contains any errors, Terraform will point them out.

  3. Deploy the cloud resources.

    1. If the configuration does not contain any errors, run this command:

      terraform apply
      
    2. Confirm creating the resources: type yes in the terminal and press Enter.

      This will create all the resources you need in the specified folder. You can check the new resources and their settings using the management console or these CLI commands:

      yc vpc network list
      

Was the article helpful?

Previous
All guides
Next
Deleting a cloud network
Yandex project
© 2025 Yandex.Cloud LLC