How to Create Private Droplets
Last verified 22 Jul 2026
DigitalOcean Droplets are Linux-based virtual machines (VMs) that run on top of virtualized hardware. Each Droplet you create is a new server you can use, either standalone or as part of a larger, cloud-based infrastructure.
Private Droplets are Droplets with VPC-only networking and no direct public connectivity. You create a Private Droplet the same way as a standard Droplet, but with public networking disabled.
Prerequisites
The automation examples below use the DigitalOcean API and, optionally, doctl.
- Create a personal access token and save it for use with the API.
- The
curlcommand is installed by default on most operating systems. Refer to your operating system documentation to install thecurlpackage if necessary. - For the
doctlexample, installdoctland rundoctl auth init.
Create Private Droplets Using the Control Panel
Create a Private Droplet from the Control Panel by following the standard Droplet creation steps. In the Networking section, clear both the Public IPv4 address and Public IPv6 address options. (Public IPv4 address is selected by default.) When both are cleared, the Control Panel shows a This Droplet will be private notice confirming the Droplet has no public IPs and can be reached only through another resource with public access in the same VPC.
Create Private Droplets Using Automation
Create Private Droplets Using the API
Send a POST request to the /v2/droplets endpoint, specifying the public_networking parameter:
curl -X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $DIGITALOCEAN_TOKEN" \
-d '{
"name": "my-private-droplet",
"region": "sfo3",
"size": "s-1vcpu-1gb",
"image": "ubuntu-24-04-x64",
"ssh_keys": [
"de:ad:be:ef:de:ad:be:ef:de:ad:be:ef:de:ad:be:ef"
],
"monitoring": true,
"with_droplet_agent": true,
"public_networking": false
}' \
"https://api.digitalocean.com/v2/droplets"The API returns information about the newly created Private Droplet.
For details on the response format, see the Create a New Droplet API documentation.
Create Private Droplets Using the CLI
Pass --enable-public-networking=false to create a Private Droplet. This matches public_networking: false in the Create Droplet API. If the flag is missing from doctl compute droplet create --help, upgrade doctl.
The following example uses the same region, size, image, and SSH key fingerprints as the API example above:
doctl compute droplet create my-private-droplet \
--region sfo3 \
--size s-1vcpu-1gb \
--image ubuntu-24-04-x64 \
--ssh-keys de:ad:be:ef:de:ad:be:ef:de:ad:be:ef:de:ad:be:ef \
--enable-public-networking=falseCreate Private Droplets Using Terraform
You can create Private Droplets with the DigitalOcean Terraform provider. See the digitalocean_droplet resource documentation for the available attributes.
Next Steps
Private Droplets have no public IP address, so you connect to them through a bastion host. See How to Connect to a Private Droplet.
For networking behavior, integrations, and limitations, see Private Droplets.