Safeguard
AI Security•

What do Claude Code cloud session network access levels allow?

Claude Code cloud sessions offer None, Trusted, Full, and Custom network access. What each level allows, what bypasses it, and how to pick one for a repo.

Safeguard Security Team
6 min read

Claude Code cloud environments set one network access level per environment: None, Trusted, Full, or Custom. Trusted, the default, allows an allowlist of package registries, GitHub, and cloud SDK hosts. Custom takes your own domain list. Some traffic, such as the GitHub proxy and the model API, follows separate rules, so the level is not the whole picture.

The four levels

Anthropic's cloud environments documentation describes each environment as a saved configuration that controls network access, environment variables, and a setup script. Each environment sets one access level for outbound connections.

LevelWhat it allowsWhen it fits
NoneNo outbound access through the session's networkTasks that need only the code already cloned
TrustedAllowlisted domains only: package registries, GitHub, cloud SDKsEveryday work that installs dependencies
FullAny domainRare cases where you accept the exposure
CustomYour own allowlist, optionally including the defaultsProjects with known internal or third party hosts

The documentation states that a new account's Default environment uses Trusted access, and that each environment has its own allowed domains list. It also says there is no organization level allowlist that admins can push to every member's environments, and no server managed setting adds domains to an environment's allowlist. A team that wants one standard list must create a shared environment and point people at it.

What the level does not control

The same documentation lists traffic that does not follow the level in the way you might assume.

  1. GitHub operations go through a dedicated proxy that keeps real credentials outside the VM, independent of the access level.
  2. The model API stays reachable for Claude Code's own requests, even at None. The security section of the cloud sessions page adds that with network access disabled, Claude Code can still communicate with the Anthropic API, which may allow data to exit the VM.
  3. Hosts listed on the environment's network secrets are reachable even when the level would not otherwise allow them, except for hosts that never receive a secret.
  4. MCP connector traffic is handled separately.
  5. All Anthropic hosted traffic passes through a security proxy used for security and abuse prevention.

Read that list as a map of channels, not a flaw. A session has to reach its model and its git host to do anything. Your job is to know which channels exist and decide whether the data they can carry is acceptable.

A worked example: choosing a level for three repositories

An illustrative scenario with three repositories.

Repository A: a public documentation site. Nothing sensitive. Trusted access is fine, because installs need registries. The risk is low, and you would not spend more effort here.

Repository B: a payments service with private packages. Start at None, run a task, and note what breaks. The install fails. Switch to Custom with your private feed and the public registry only. Keep the default hosts off if you do not use them. Add a network secret for the private feed so the token is not an environment variable.

Repository C: an internal tool that calls two partner APIs in tests. Use Custom with the two partner hosts, but ask whether the tests need live partners at all. A mock keeps the destination closed.

The pattern is to begin closed and open on evidence, which matches what the documentation offers: Custom exists so you can list one domain per line instead of widening to Full.

Steps to configure a Custom environment

  1. Create or edit an environment and pick Custom.
  2. List one domain per line. The documentation shows examples that allow a host, any subdomain of a domain, and a registry host.
  3. Decide whether to include the default list. Excluding it narrows access.
  4. Add network secrets for any credentials, so tokens are attached to requests outside the VM rather than read from variables.
  5. Run a representative task and read what fails.
  6. Record the owner and reason for each domain.

Pitfalls

  • Treating Trusted as a security control for sensitive code. It is a convenience default. Review the default allowed domains against your threat model.
  • Putting tokens in environment variables. The documentation says any command Claude runs can read them, and anyone who uses the environment can read them. Use a network secret where the proxy can attach the key.
  • Forgetting the model channel. None does not mean no data can leave.
  • Per user environments with no owner. Since there is no organization wide allowlist push, drift is likely unless you standardize on a shared environment.

Try it yourself

Click through it at your own pace, or open it full screen.

Look at how a guardrail sits between an agent and the tools it can call, which is the same kind of boundary a network level draws for outbound traffic.

Where Safeguard fits

Safeguard does not set Claude Code network levels. Its MCP Guardrail, agent identity, and policies and gates cover what agents and their tools may do, and dependency scanning covers what an allowed registry delivers.

Quick check

Does None mean no data can leave a Claude Code cloud session?

No. The documentation says the model API connection remains, which may allow data to exit the VM. None removes outbound access through the session's network, not every channel.

Can an admin push one allowlist to every member?

Per the documentation, there is no organization level allowlist and no server managed setting adds domains. Owners can create shared environments that members use instead.

Should private package tokens go in environment variables?

Avoid it. Environment values are readable by any command the agent runs. Use a network secret so a proxy attaches the key after the request leaves the VM.

Sources

Last reviewed: 19 October 2026.

Never miss an update

Weekly insights on software supply chain security, delivered to your inbox.

Self-healing security runs on Safeguard.

Your first fix PR is minutes away.

No sales call required, even your agent can complete the purchase over MCP.