Deploy any Hugging Face model as an API
Go from a Hugging Face model ID to a live, autoscaling endpoint with one Python file. Beam builds the container, manages the GPUs, and caches your weights between requests.
The shortest path from Hub to production
No Dockerfiles, no serving framework to stand up. Declare your dependencies in Python and Beam handles the rest.
Ship a model in three steps
Pick a model
Reference any Hub model ID from transformers, diffusers, or sentence-transformers — or bring your own weights.
Wrap it in an endpoint
Add the @endpoint decorator with your GPU and image. Load the model in on_start so it stays warm.
Serve, then deploy
Iterate with beam serve's live reload, then beam deploy gives you a production HTTPS endpoint.
# Develop against the cloud with live reload
$ beam serve app.py:predict
=> Watching for changes...
# Deploy to production
$ beam deploy app.py:predict
=> Deployed 🎉
=> https://hf-inference-abc123.app.beam.cloud
$ curl -X POST https://hf-inference-abc123.app.beam.cloud \
-H 'Authorization: Bearer YOUR_TOKEN' \
-d '{"prompt": "Explain serverless GPUs"}'Frequently asked questions
Which libraries are supported?
Anything pip-installable: transformers, diffusers, sentence-transformers, ultralytics, or your own packages. You define the image in Python and Beam builds it.
Can I deploy gated or private models?
Yes. Save your Hugging Face token with beam secret create HF_TOKEN and the container authenticates to the Hub securely.
Do weights re-download on every cold start?
Not if you cache them. Download weights to a persistent volume once, and every container loads from disk instead of the Hub.
How do I pick the right GPU?
Start small — a T4 handles many models under a few billion parameters — and watch real-time GPU utilization in the Beam dashboard to right-size from there.
What about chat models with an OpenAI-style API?
Use Beam's vLLM integration: it serves any compatible Hub model behind an OpenAI-compatible API, so existing clients work unchanged.
Related use cases
Deploy open-source LLMs
Serve open-source LLMs behind an autoscaling, OpenAI-compatible API.
InferenceRun Whisper transcription behind your own API
On-demand Whisper transcription behind an autoscaling API.
InferenceDeploy computer vision models at scale
Detection, segmentation, and classification behind managed APIs.
Start shipping on infra
you won’t outgrow.
Run sandboxes and GPU workloads on your cloud, and scale out to ours when you need to. No infra to manage.