What is Modal?
Modal is a serverless compute platform built for AI, machine learning and data teams. You write ordinary Python, add a few decorators to say what container image and hardware a function needs, and Modal runs it in the cloud, scaling from zero to many GPUs or CPUs and back again. There are no clusters, Kubernetes files or Dockerfiles to manage, and you pay for the compute you actually use.
Key features
- Infrastructure in code: define images, GPUs, secrets and schedules in Python.
- GPUs on demand: attach GPUs to functions for inference, fine-tuning and training.
- Fast autoscaling: containers spin up quickly and scale to zero when idle.
- Web endpoints: expose functions as HTTPS APIs, including FastAPI and other ASGI or WSGI apps.
- Batch and parallel jobs: fan work out across many containers with
.map(). - Sandboxes: run untrusted or AI-generated code in isolated containers.
- Storage: Volumes, Dicts, Queues and cloud bucket mounts.
- Scheduling: cron and periodic jobs.
Who is it for?
Modal is for ML engineers, AI startups and data teams who want GPU and CPU compute without running their own infrastructure, and for developers deploying model inference APIs or AI agents that need to execute code.
Use cases
- Serving open-source LLMs, image or audio models as APIs
- Fine-tuning and training models on cloud GPUs
- Large batch jobs such as embeddings, transcription or data processing
- Code execution sandboxes for AI agents
- Scheduled data pipelines
Pricing
Modal charges per second for the CPU, GPU and memory your functions use, and its plans include a monthly amount of free credits. Rates differ by GPU type, so check the official Modal pricing page.
What's new and trending
Modal's Python SDK 1.6.2 was released on October 15, 2026. It introduced a new metrics surface with modal function metrics and modal server metrics CLI commands for exporting detailed, time-resolved performance and resource data (release notes).
Getting started
- Sign up at modal.com.
- Install the client with
pip install modaland runmodal setupto authenticate. - Write a Python file with an
Appand a function decorated with@app.function(). - Run it in the cloud with
modal run your_file.py. - Deploy persistent apps and endpoints with
modal deploy(guide).
Alternatives
RunPod and Lambda offer GPU cloud instances and serverless GPUs, while Replicate and Baseten focus on model hosting and inference. For code execution sandboxes, compare E2B and Daytona.
FAQ
Do I need Docker or Kubernetes to use Modal? No. You define container images and hardware in Python, and Modal handles the rest.
Does Modal support GPUs? Yes. You can request GPUs per function for inference, training and batch work.
How does Modal billing work? You pay per second for the resources your functions use, with free monthly credits included in plans.
Can I serve a web API on Modal? Yes. Modal supports web endpoints and full ASGI or WSGI apps such as FastAPI.
Which languages does Modal support? Modal is Python-first. Check the docs for current support for other languages.

