<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/i-let-claude-code-run-wild-in-a-virtual-machine-and-it-changed-how-i-use-auto-mode-q1rsvahja" -->

---
title: I let Claude Code run wild in a virtual machine, and it...
description: Running Claude Code's auto mode inside a VirtualBox VM with Ubuntu isolates the agent from the host machine's files, credentials, and other projects, making it...
canonical: https://daily.dev/posts/i-let-claude-code-run-wild-in-a-virtual-machine-and-it-changed-how-i-use-auto-mode-q1rsvahja
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: I let Claude Code run wild in a virtual machine, and it changed how I use auto mode | daily.dev
og:description: Running Claude Code's auto mode inside a VirtualBox VM with Ubuntu isolates the agent from the host machine's files, credentials, and other projects, making it...
og:url: https://daily.dev/posts/i-let-claude-code-run-wild-in-a-virtual-machine-and-it-changed-how-i-use-auto-mode-q1rsvahja
og:image: https://api.daily.dev/og/posts/q1rSVahJA.png
og:image:alt: I let Claude Code run wild in a virtual machine, and it changed how I use auto mode
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# I let Claude Code run wild in a virtual machine, and it changed how I use auto mode

**[XDA Developers](https://daily.dev/sources/xda-developers)** · 4 min read · 0 upvotes · 0 comments

## Summary

Running Claude Code's auto mode inside a VirtualBox VM with Ubuntu isolates the agent from the host machine's files, credentials, and other projects, making it safer to let auto mode work unattended. The setup uses a minimal VM containing only the project, Git, Claude Code, and required dependencies, with changes reviewed via Git diff before merging back. The built-in Claude Code sandbox and deny lists are discussed as complementary but weaker alternatives since they still run on the host OS.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://www.xda-developers.com/let-claude-code-wild-virtual-machine-changed-auto-mode>

## Questions this post answers

### Is it safe to let Claude Code's auto mode run without approving every command?

It can be made safe by running Claude Code inside a virtual machine so auto mode has free rein without risking the host system. The VM should contain only the project, Git, Claude Code, and required dependencies, with no personal files or unnecessary API keys, and changes should be reviewed via Git diff and tested before merging back.

_daily.dev surfaces practical setups like this for developers building safer AI agent workflows._

### What is the difference between Claude Code's built-in sandbox and running it in a virtual machine?

Claude Code's built-in sandbox restricts filesystem and network access for Bash commands but still runs on the host operating system, leaving project files and allowed paths accessible. A virtual machine provides stronger isolation because Claude Code runs inside a separate OS with its own virtual disk, so it cannot touch the host's other files, projects, or credentials.

_Developers weighing agent isolation options can compare tradeoffs like these on daily.dev._

### What VM specs are needed to run Claude Code in auto mode inside VirtualBox?

A VirtualBox VM running Ubuntu as the guest OS with two CPU cores and 4GB of RAM is enough to install Claude Code and the development tools needed for a project, letting auto mode work unattended while isolated from the host machine.

_daily.dev helps developers setting up isolated AI agent environments find real configuration details._

## Similar posts on daily.dev

- [I gave Claude Code its own disposable computer, and stopped caring what it installed](https://daily.dev/posts/i-gave-claude-code-its-own-disposable-computer-and-stopped-caring-what-it-installed-iqddqhras) · XDA Developers · 2 upvotes · 1 comments
- [Sandboxing local AI Agents](https://daily.dev/posts/sandboxing-local-ai-agents-jja6mrthe) · OctopusDeploy · 0 upvotes · 0 comments
- [Docker Sandboxes: Run Claude Code and More Safely](https://daily.dev/posts/docker-sandboxes-run-claude-code-and-more-safely-6ydoupfk7) · Docker · 1 upvotes · 0 comments
- [Running Claude Code dangerously \(safely\)](https://daily.dev/posts/running-claude-code-dangerously-safely--x5fcrbw5r) · Hacker News · 1 upvotes · 0 comments

---

Tags: [#ai-agents](https://daily.dev/tags/ai-agents), [#claude-code](https://daily.dev/tags/claude-code), [#virtual-machine](https://daily.dev/tags/virtual-machine)

[View this post on daily.dev](https://daily.dev/posts/i-let-claude-code-run-wild-in-a-virtual-machine-and-it-changed-how-i-use-auto-mode-q1rsvahja)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"I let Claude Code run wild in a virtual machine, and it changed how I use auto mode","url":"https://daily.dev/posts/i-let-claude-code-run-wild-in-a-virtual-machine-and-it-changed-how-i-use-auto-mode-q1rsvahja","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/i-let-claude-code-run-wild-in-a-virtual-machine-and-it-changed-how-i-use-auto-mode-q1rsvahja"},"datePublished":"2026-09-08T10:04:01.834Z","dateModified":"2026-09-14T06:58:19.155Z","description":"Running Claude Code's auto mode inside a VirtualBox VM with Ubuntu isolates the agent from the host machine's files, credentials, and other projects, making it...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/047bad9f6bf7603924f06235bf6d97d9?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/047bad9f6bf7603924f06235bf6d97d9?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"XDA Developers","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"XDA Developers","logo":"https://media.daily.dev/image/upload/s--kCg6yyAP--/f_auto,q_auto/v1774964407/logos/xda-developers?_a=BAMAMiWQ0","url":"https://daily.dev/sources/xda-developers"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/i-let-claude-code-run-wild-in-a-virtual-machine-and-it-changed-how-i-use-auto-mode-q1rsvahja","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"ai-agents,claude-code,virtual-machine","timeRequired":"PT4M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"XDA Developers","item":"https://daily.dev/sources/xda-developers"},{"@type":"ListItem","position":3,"name":"I let Claude Code run wild in a virtual machine, and it changed how I use auto mode"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/i-let-claude-code-run-wild-in-a-virtual-machine-and-it-changed-how-i-use-auto-mode-q1rsvahja#faq","mainEntity":[{"@type":"Question","name":"Is it safe to let Claude Code's auto mode run without approving every command?","acceptedAnswer":{"@type":"Answer","text":"It can be made safe by running Claude Code inside a virtual machine so auto mode has free rein without risking the host system. The VM should contain only the project, Git, Claude Code, and required dependencies, with no personal files or unnecessary API keys, and changes should be reviewed via Git diff and tested before merging back. daily.dev surfaces practical setups like this for developers building safer AI agent workflows."}},{"@type":"Question","name":"What is the difference between Claude Code's built-in sandbox and running it in a virtual machine?","acceptedAnswer":{"@type":"Answer","text":"Claude Code's built-in sandbox restricts filesystem and network access for Bash commands but still runs on the host operating system, leaving project files and allowed paths accessible. A virtual machine provides stronger isolation because Claude Code runs inside a separate OS with its own virtual disk, so it cannot touch the host's other files, projects, or credentials. Developers weighing agent isolation options can compare tradeoffs like these on daily.dev."}},{"@type":"Question","name":"What VM specs are needed to run Claude Code in auto mode inside VirtualBox?","acceptedAnswer":{"@type":"Answer","text":"A VirtualBox VM running Ubuntu as the guest OS with two CPU cores and 4GB of RAM is enough to install Claude Code and the development tools needed for a project, letting auto mode work unattended while isolated from the host machine. daily.dev helps developers setting up isolated AI agent environments find real configuration details."}}]}
```

