Skip to content

Network Limits (Firewall)

View as Markdown

Network limits control outbound internet access from sandboxes. Each sandbox runs behind a firewall that restricts which external IP addresses and domains it can reach, preventing untrusted code from exfiltrating data or contacting arbitrary hosts.

Default network policies are applied automatically based on your organization’s tier. You can also configure access per sandbox using three parameters:

  • networkAllowList for IPv4 CIDR ranges
  • domainAllowList for domains and wildcard domains
  • networkBlockAll to block all outbound traffic

Set these parameters when creating a sandbox or update them while the sandbox is running.

Network limits are automatically applied to sandboxes based on your organization’s billing tier. This provides secure and controlled internet access for development environments:

  • Tier 1 & Tier 2: Network access is restricted and cannot be overridden at the sandbox level. Organization-level network restrictions take precedence over sandbox-level settings. Even with networkAllowList or domainAllowList specified when creating a sandbox, the organization’s network restrictions still apply
  • Tier 3 & Tier 4: Full internet access is available by default, with the ability to configure custom network settings

Essential services are available on all tiers and include services essential for development: package registries, container registries, Git repositories, CDN services, platform services, system package managers, and more

Create sandboxes with network restrictions

Section titled “Create sandboxes with network restrictions”

Create a sandbox with network restrictions to control outbound internet access.

The options are mutually exclusive. Set at most one non-empty value. Sending a conflicting combination returns a 400 error. Empty-string allow lists count as unset and never conflict.

from daytona import CreateSandboxFromSnapshotParams, Daytona
daytona = Daytona()
# Allow access to specific IP addresses (Wikipedia, X/Twitter, private network)
sandbox = daytona.create(CreateSandboxFromSnapshotParams(
network_allow_list='208.80.154.232/32,199.16.156.103/32,192.168.1.0/24'
))
# Allow access to specific domains
sandbox = daytona.create(CreateSandboxFromSnapshotParams(
domain_allow_list='example.com,*.daytona.io'
))
# Or block all network access
sandbox = daytona.create(CreateSandboxFromSnapshotParams(
network_block_all=True
))

Update network settings while a sandbox is running

Section titled “Update network settings while a sandbox is running”

Update network settings for running sandboxes.

This operation requires the WRITE_SANDBOXES permission. Organizations on Tier 3 and Tier 4 can change outbound firewall policy on a running sandbox. The API applies the new rules and persists them on the sandbox. The sandbox keeps running; stop or start are not required.

Organizations on Tier 1 or Tier 2 cannot override network policy at the sandbox level, and the API returns an error in that case.

  • Sending networkAllowList as an empty string clears a stored CIDR allow list
  • Sending domainAllowList as an empty string clears a stored domain allow list
  • Sending networkBlockAll: true blocks all outbound traffic and clears both the stored CIDR and domain allow lists
  • Sending only networkBlockAll: false removes the block-all rule and clears both the stored CIDR and domain allow lists
# Block all outbound traffic (clears the CIDR allow list)
sandbox.update_network_settings(network_block_all=True)
# Remove the block-all rule and clear the CIDR allow list
sandbox.update_network_settings(network_block_all=False)
# Apply or replace a CIDR allow list (implies not blocking all)
sandbox.update_network_settings(
network_allow_list='208.80.154.232/32,192.168.1.0/24'
)
# Apply or replace a domain allow list
sandbox.update_network_settings(
domain_allow_list='example.com,*.daytona.io'
)
# Clear a stored CIDR allow list (empty string). Outbound traffic still follows `network_block_all`.
sandbox.update_network_settings(network_allow_list='')
# Clear a stored domain allow list
sandbox.update_network_settings(domain_allow_list='')

The network allow list is a comma-separated list of IPv4 CIDR blocks.

  • IPv4 only: hostnames, domains, and IPv6 are not supported
  • CIDR required: every entry must include a / prefix length integer in the range 0 to 32 (inclusive), for example: /32
  • CIDR format: use standard CIDR notation (A.B.C.D/N). Do not include extra / segments
  • Max 10 entries: the list cannot contain more than 10 comma-separated items
  • Whitespace is ignored: entries are trimmed, so spaces around commas are ok

Examples:

  • Single IP: 208.80.154.232/32 (Wikipedia)
  • Subnet: 192.168.1.0/24 (Private network)
  • Multiple networks: 208.80.154.232/32,199.16.156.103/32,10.0.0.0/8

The domain allow list is a comma-separated list of DNS domains. When a domain allow list is set, outbound traffic is limited to the listed domains and other external domains are blocked.

  • Domains only: use hostnames such as example.com or api.openai.com. Do not include protocols, paths, ports, or query strings
  • Wildcards supported: prefix a domain with *. to allow the base domain and its subdomains, for example *.daytona.io
  • Max 20 entries: the list cannot contain more than 20 comma-separated items
  • Whitespace is ignored: entries are trimmed, so spaces around commas are ok
  • Clear on update: send domainAllowList as an empty string when updating network settings to clear a stored domain allow list

Examples:

  • Single domain: example.com
  • Wildcard domain: *.daytona.io
  • Multiple domains: example.com,*.daytona.io,api.openai.com

To test network connectivity from your sandbox:

Terminal window
# Test HTTP connectivity to allowed addresses
curl -I https://208.80.154.232
# Test HTTP connectivity to allowed domains
curl -I https://example.com
# Test package manager access (allowed on all tiers)
apt update # For Ubuntu/Debian
npm ping # For Node.js
pip install --dry-run requests # For Python

Network limits provide several security advantages:

  • Prevents data exfiltration from sandboxes
  • Reduces attack surface by limiting external connections
  • Complies with security policies for development environments
  • Enables fine-grained control over network access

Essential services are available on all tiers and include services essential for development.

ServiceDomains
NPM Registryregistry.npmjs.org, registry.npmjs.com, nodejs.org, nodesource.com, deb.nodesource.com, npm.pkg.github.com
Yarn Packagesyarnpkg.com, *.yarnpkg.com, yarn.npmjs.org, yarnpkg.netlify.com
Bunbun.sh, *.bun.sh
ServiceDomains
Nixcache.nixos.org, channels.nixos.org, releases.nixos.org
ServiceDomains
GitHubgithub.com, *.github.com, *.githubusercontent.com, gh.io, ghcr.io
GitLabgitlab.com, *.gitlab.com
Bitbucketbitbucket.org
Code Storagecode.storage, *.code.storage
Azure DevOpsdev.azure.com, *.dev.azure.com, login.microsoftonline.com, visualstudio.com, *.visualstudio.com, ssh.dev.azure.com, vs-ssh.visualstudio.com
ServiceDomains
PyPIpypi.org, pypi.python.org, files.pythonhosted.org, bootstrap.pypa.io, astral.sh, *.astral.sh
Condarepo.anaconda.com
ServiceDomains
Rustcrates.io, static.crates.io, index.crates.io, static.rust-lang.org, rustup.rs, sh.rustup.rs, doc.rust-lang.org
ServiceDomains
Goproxy.golang.org, sum.golang.org, index.golang.org, go.dev, golang.org, *.golang.org
ServiceDomains
CMakecmake.org
ServiceDomains
Composerpackagist.org, *.packagist.org, packagist.com
ServiceDomains
NuGetnuget.org, *.nuget.org
ServiceDomains
Hexhex.pm, *.hex.pm
ServiceDomains
RubyGemsrubygems.org, *.rubygems.org
ServiceDomains
Ubuntu Repos*.ubuntu.com
Debian Repos*.debian.org, cdn-fastly.deb.debian.org
ServiceDomains
CDN Servicesfastly.com, cloudflare.com, gateway.ai.cloudflare.com, *.workers.dev, r2.cloudflarestorage.com, *.r2.cloudflarestorage.com
JavaScript CDNsunpkg.com, jsdelivr.net
ServiceDomains
Anthropic*.anthropic.com, claude.ai, *.claude.ai, platform.claude.com
OpenAIopenai.com, *.openai.com, chatgpt.com
Google AIgenerativelanguage.googleapis.com, gemini.google.com, aistudio.google.com, ai.google.dev, models.dev
Perplexityapi.perplexity.ai
DeepSeekapi.deepseek.com
Groqapi.groq.com
Expoapi.expo.dev
OpenRouteropenrouter.ai
Qwenchat.qwen.ai, dashscope.aliyuncs.com, dashscope-intl.aliyuncs.com
Cursorcursor.com, *.cursor.com, *.cursor.sh
OpenCodeopencode.ai, *.opencode.ai
Aideraider.chat
Hugging Facehuggingface.co, *.huggingface.co, hf.co, *.hf.co, *.xethub.hf.co, *.cdn.hf.co, *.aws.cdn.hf.co, *.gcp.cdn.hf.co
Other AI Servicesapi.letta.com, api.fireworks.ai, open.bigmodel.cn, *.z.ai, *.moonshot.ai, *.minimax.io, *.kimi.com, ai-gateway.vercel.sh, api.elevenlabs.io, api.featherless.ai, ampcode.com, *.ampcode.com, *.openai.azure.com, *.services.ai.azure.com, trynia.ai, *.trynia.ai, api.x.ai, copass.id, *.copass.id, zenmux.ai, *.devin.ai
ServiceDomains
Docker Registriesdocker.io, *.docker.io, *.docker.com
Microsoft Container Registrymcr.microsoft.com
Kubernetes Registryregistry.k8s.io
Google Container Registrygcr.io, *.gcr.io, *.pkg.dev, registry.cloud.google.com
Quayquay.io, quay-registry.s3.amazonaws.com
AWS ECRpublic.ecr.aws, *.ecr.aws
ServiceDomains
Maven Reposrepo1.maven.org, repo.maven.apache.org
ServiceDomains
Google Fontsfonts.googleapis.com, fonts.gstatic.com
RegionDomains
US East*.us-east-1.amazonaws.com, *.us-east-2.amazonaws.com
US West*.us-west-1.amazonaws.com, *.us-west-2.amazonaws.com
EU*.eu-central-1.amazonaws.com, *.eu-central-2.amazonaws.com, *.eu-north-1.amazonaws.com, *.eu-south-1.amazonaws.com, *.eu-south-2.amazonaws.com, *.eu-west-1.amazonaws.com, *.eu-west-2.amazonaws.com, *.eu-west-3.amazonaws.com
Asia Pacific*.ap-south-1.amazonaws.com
ServiceDomains
Google Cloud Platformaccounts.google.com, *.googleapis.com, *.storage.googleapis.com, *.gstatic.com
Google Downloadsdl.google.com
Google Package Registrypackages.cloud.google.com
ServiceDomains
Azure Blob Storage*.blob.core.windows.net
Boxapi.box.com, app.box.com, *.app.box.com, upload.box.com, account.box.com, *.ent.box.com, *.boxcloud.com
ServiceDomains
Daytonaapp.daytona.io
ServiceDomains
Convexconvex.dev, *.convex.dev, *.convex.cloud, *.convex.site
Herokuherokuapp.com, *.herokuapp.com
Vercelvercel.com, *.vercel.com, *.vercel.app
Supabasesupabase.com, *.supabase.com, supabase.co, *.supabase.co
Clerkclerk.com, *.clerk.com, clerk.dev, *.clerk.dev, accounts.dev, *.accounts.dev, clerk.accounts.dev, *.clerk.accounts.dev
WorkOSworkos.com, *.workos.com, authkit.app, *.authkit.app
Inngestinngest.com, *.inngest.com
PostHogposthog.com, *.posthog.com
Sentrysentry.io, *.sentry.io, sentry-cdn.com, *.sentry-cdn.com
Linearlinear.app, *.linear.app
Figmafigma.com, *.figma.com, *.figmafiles.com
ClickUpclickup.com, *.clickup.com
Atlassianacli.atlassian.com
Railwayrailway.app, *.railway.app, railway.com, *.railway.com
Autumnapi.useautumn.com
Playwrightplaywright.dev, cdn.playwright.dev
Dopplerdoppler.com, *.doppler.com
Auth0auth0.com, *.auth0.com
Sanitysanity.io, *.sanity.io, sanity.work, *.sanity.work
Shopifyshopify.com, *.shopify.com, *.myshopify.com, *.shopify.dev, *.shopifycdn.com
Mesamesa.dev, *.mesa.dev
Buildkitebuildkite.com, *.buildkite.com
Shortcutapi.app.shortcut.com, app.shortcut.com
USAspendingapi.usaspending.gov, files.usaspending.gov
Logo Devimg.logo.dev, logo.dev
Kiro*.kiro.dev, *.us-east-1.kiro.dev, prod.download.cli.kiro.dev
Browserbasebrowserbase.com, *.browserbase.com, connect.usw2.browserbase.com, connect.use1.browserbase.com, connect.euc1.browserbase.com, connect.apse1.browserbase.com
ServiceDomains
Telegramapi.telegram.org
WhatsAppweb.whatsapp.com, *.whatsapp.net
ServiceDomains
Langfuse*.langfuse.com, *.cloud.langfuse.com
LangSmithapi.smith.langchain.com