AI/ML developers
You need GPU sandboxes for inference and live-training without managing Kubernetes. Modal's deployment flow runs from days to minutes with a Python decorator and automatic autoscaling.
Direct Answer
A code sandbox is an isolated execution environment that runs untrusted or experimental code safely, preventing resource conflicts and security breaches. Modern cloud sandboxes provide containerized workspaces with dedicated compute, networking isolation, and automatic cleanup after execution. Modal is a code sandbox platform for AI, developers and data scientists that combines secure code execution with GPU snapshotting for sub-second cold starts and elastic scaling across multi-cloud infrastructure.
What you can build
Modal Sandboxes give you isolated, ephemeral environments that scale from zero to thousands of GPUs in seconds with no infrastructure to manage.
Scale to zero between requests and handle traffic spikes without pre-provisioning capacity.
Run embedding generation, video transcoding, or dataset preprocessing across hundreds of CPUs in parallel.
Run user-submitted scripts safely with CPU and memory limits, network restrictions, and timeout enforcement.
Spin up A100 or H100 GPUs on demand and terminate automatically when training completes.


Run pip install modal, decorate a Python function with @app.function(gpu="A100"), and define dependencies inline. Modal builds a container image automatically and caches layers for instant reuse. No Dockerfile. No registry push.
Run modal deploy to push your function live with automatic HTTPS endpoints, autoscaling, and logging enabled. Modal selects a cloud region with GPUs in stock, pulls the cached sandbox container, and starts execution in under one second.
Call your function via Python client, REST API, or cron schedule, then watch logs and GPU metrics in the Modal dashboard. If 500 requests arrive simultaneously, Modal spawns 500 sandboxes in parallel. Traffic drops to zero — Modal scales down and changes nothing.
Lovable scales 250,000 app creations in 48 hours
"Modal was the only infrastructure provider that enabled us to reliably run tens of thousands of app creation sessions in an instant. We're excited to build with them for the long term."
Lovable — which hit $76M ARR in 7 months — uses Modal Sandboxes to run LLM-generated code for every creation session. During a viral promotion event with Anthropic, OpenAI, and Google, Modal handled a 2.6x surge in concurrent sessions: over 1 million sandboxes ran during the event, powering up to 25,000 concurrent sandboxes at peak. Lovable's platform team was not paged once across the entire weekend.
Anton Osika, Founder and CEO at Lovable

Who benefits most
You need GPU sandboxes for inference and live-training without managing Kubernetes. Modal's deployment flow runs from days to minutes with a Python decorator and automatic autoscaling.
Run experiments on a remote cluster without configuration headaches. Modal parallelizes jobs across hundreds of GPUs within seconds during a session.
Lock and test new code safely from production. Code sandboxes let your team make confident bets without threatening your infrastructure model.
Access H100 GPU slots instantly. Modal's multi-cloud capacity pool eliminates quota waits and reserved instance delays.
Who benefits most
You need GPU sandboxes for inference and live-training without managing Kubernetes. Modal's deployment flow runs from days to minutes with a Python decorator and automatic autoscaling.
Run experiments on a remote cluster without configuration headaches. Modal parallelizes jobs across hundreds of GPUs within seconds during a session.
Lock and test new code safely from production. Code sandboxes let your team make confident bets without threatening your infrastructure model.
Access H100 GPU slots instantly. Modal's multi-cloud capacity pool eliminates quota waits and reserved instance delays.
"We use Modal to run edge inference with <10ms overhead and batch jobs at large scale. Our team loves the platform for the power and flexibility it gives us."
Brian Ichter, Co-founder
"Modal makes it easy to write code that runs on 100s of GPUs in parallel, transcribing podcasts in a fraction of the time."
Mike Cohen, Head of Data
"Everyone here loves Modal because it helps us move so much faster. We rely on it to handle massive spikes in volume for evals, RL environments, and MCP servers."
Aakash Sabharwal, VP of Engineering
"Modal was the only infrastructure provider that enabled us to reliably run tens of thousands of app creation sessions in an instant. We're excited to build with them for the long term."
Anton Osika, CEO & Founder
Igor KotuaEngineer, The Linux FoundationIf you building AI stuff with Python and haven't tried @modal you are missing out big time
CalebML Engineer, Hugging FaceBullish on @modal - Great Docs + Examples - Healthy Free Plan (30$ free compute / month) - Never have to worry about infra / just Python
Daniel RothenbergCo-founder, Brightband@modal continues to be magical... 10 minutes of effort and the `joblib`-based parallelism I use to test on my local machine can trivially scale out on the cloud. Makes life so easy!
@mattzcarey.com on blskyAI Engineer, StackOne@modal has got a bunch of stuff just worked out this should be how you deploy python apps. wow
Erin BoyleML Engineer, TeslaThis tool is awesome. So empowering to have your infra needs met with just a couple decorators. Good people, too!
Aman KishoreResearch Engineer, HarveyIf you are still using AWS Lambda instead of @modal you're not moving fast enough
Jai ChopraProduct, LanceDBRecently built an app on Lambda and just started to use @modal, the difference is insane! Modal is amazing, virtually no cold start time, onboarding experience is great
Izzy MillerDevRel, Hexspecial shout out to @modal for providing the crucial infrastructure to run this! Modal is the coolest tool I've tried in a really long time. Cannot say enough good things.
Modal natively supports Python, and you can run virtually any language inside a sandbox by installing it as a dependency in your container image. Teams regularly run Node.js, Ruby, PHP, Rust, and shell scripts inside Modal Sandboxes.
Each Modal sandbox runs in its own container with dedicated CPU, memory, and GPU resources. Network namespaces prevent cross-tenant communication and Modal's runtime enforces strict process boundaries, 100x faster than Docker.
Yes. Modal Sandboxes are designed for exactly this use case. You can define resource limits (CPU, memory, GPU), network restrictions, timeouts, and filesystem access controls. Many companies run user-submitted code through Modal Sandboxes in production.
Modal achieves sub-second cold starts for pre-cached containers. For GPU workloads, Modal's snapshot technology lets you checkpoint a running container and restore it in under a second on a fresh GPU, something that typically takes 2-10 minutes on other platforms.
No. Modal charges per second of actual compute usage. When your sandbox finishes executing, billing stops immediately. There are no idle fees, no reserved instance costs, and no minimum usage requirements.
Modal can run workloads that were previously containerized with Docker. You can import existing Docker images and run them on Modal, removing the need to manage Kubernetes clusters or Docker registries yourself.