A Space is a Git repo that runs an app
Behind the URL huggingface.co/spaces/{org}/{name} is a Git-backed repository with one file that matters: a manifest declaring the SDK (gradio, streamlit, docker, or static). Push to the repo, and HF builds and runs the app on managed hardware. Free CPU tier; paid GPU tiers up to A100 / H100.
Three SDK families
- Gradio — component-first Python UI. Easiest path for ML demos. Auto-generates an inputs/outputs UI from a Python function signature.
- Streamlit — script-first Python UI. Better for dashboards and richer state. Slightly more code than Gradio for the same demo.
- Docker — arbitrary container. Anything you can put in a Dockerfile. Required for non-Python apps, custom Nginx, custom GPU drivers, FastAPI servers.
- Static — HTML / CSS / JS hosted, no runtime. Good for documentation, landing pages, model showcases.
What Spaces are not
Not a general PaaS. Not a database backend (no persistent disk on free tier; persistent storage on paid tiers is limited). Not a long-running task queue. Spaces is for "one app, often a model demo, served from the Hub" — great for that, weak for everything else.