What Home Assistant asks of a server
The answer depends on which of the two installation types you pick. The project recommends Home Assistant OS for most people because it is the easiest to install and keep current, and only the OS gives you apps (what used to be called add-ons). Home Assistant Container is the same core in a Docker image, with no apps and updates you run yourself.
| Install type | What the docs ask for | Where it runs here |
|---|---|---|
| Home Assistant OS in a VM | 2 vCPUs and 2 GB of memory at minimum, UEFI boot, the KVM image in qcow2 format; the KVM guide's default disk is 32 GB | A whole server running Proxmox VE |
| Home Assistant Container | Docker with host networking; no separate memory floor is stated, and a Raspberry Pi 3 is among the listed boards | A Cloud VPS with the Docker app |
Before sizing anything, look at how your devices connect. Every integration page names an IoT class. Cloud Polling and Cloud Push integrations reach the device through its maker's servers and need an internet connection, so they behave the same from New York as from your hallway. Local Polling and Local Push integrations talk to the device directly, which a server in a data centre cannot do without a tunnel back to your home.
The server that fits
For Home Assistant Container, a Cloud VPS in New York is enough. You get root access, your own IPv4 address and an IPv6 /96, a console in the browser for the day SSH stops answering, and reinstalls from the dashboard. Pick the free Docker app when you order and the machine comes up on Ubuntu 24.04 with Docker and Docker Compose installed: the machine is usually built within a couple of minutes of payment, and the app is ready a few minutes after it starts. Start small: moving up a size later keeps your files and addresses after one restart, though sizes never shrink.
Home Assistant OS is a different story. A Cloud VPS installs Ubuntu, Debian, AlmaLinux or Rocky Linux only, so the OS image has no place there. On a Proxmox VE dedicated server it does: Proxmox VE 9 is a free one-click image, its virtual machines run on KVM, and the Home Assistant KVM image is the one to import. The project's own guide covers plain KVM rather than Proxmox, so expect to translate its settings (UEFI, 2 vCPUs, 2 GB) into the Proxmox wizard yourself. The whole machine is yours, the port is unmetered, and a racked one goes live about half an hour after approval.
Up and running in an evening
These steps set up Home Assistant Container on a Cloud VPS with the Docker app, with port 8123 never open to the internet. You need a domain name with an A record and an AAAA record pointing at the server.
- Log in over SSH as root. Allow SSH through the firewall before you turn it on, then open the web ports:
sudo ufw allow 22,sudo ufw allow 80/tcp,sudo ufw allow 443/tcp, thensudo ufw enable. ufw applies the same rules to IPv6 unless/etc/default/ufwsaysIPV6=no;sudo ufw statuslists the(v6)rules so you can check. - Make a folder with
sudo mkdir -p /opt/homeassistantand create/opt/homeassistant/compose.yamlwith the block below, copied from the official guide. Change/PATH_TO_YOUR_CONFIGto/opt/homeassistant/configand setTZto your own time zone. - Start it from that folder with
docker compose up -d. - From your own computer, open a tunnel:
ssh -L 8123:localhost:8123 root@YOUR_SERVER_IP. Leave it open and browse tohttp://localhost:8123. - Select Create my smart home and make your account straight away. The first account becomes the owner and an administrator, and whoever reaches the page first gets it; the tunnel and the closed port mean that can only be you.
- Install Caddy and put it in front of Home Assistant, as shown in the next section.
services:
homeassistant:
container_name: homeassistant
image: "ghcr.io/home-assistant/home-assistant:stable"
volumes:
- /PATH_TO_YOUR_CONFIG:/config
- /etc/localtime:/etc/localtime:ro
- /run/dbus:/run/dbus:ro
restart: unless-stopped
stop_grace_period: 60s
privileged: true
network_mode: host
environment:
TZ: Europe/Amsterdam
New to Docker? Our guide to running one app with Docker Compose behind HTTPS covers the same pieces on something simpler.
Reaching it from your phone, safely
Put a reverse proxy in front and keep 8123 closed. The project warns that just opening a port is not secure and that remote traffic should be encrypted. Caddy fetches a certificate on its own when it knows your domain and ports 80 and 443 are open, adds the X-Forwarded-For header, and carries WebSocket connections through. Install it with the commands from Caddy's own instructions:
sudo apt install --yes debian-keyring debian-archive-keyring apt-transport-https curl
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | sudo gpg --dearmor -o /usr/share/keyrings/caddy-stable-archive-keyring.gpg
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | sudo tee /etc/apt/sources.list.d/caddy-stable.list
sudo chmod o+r /usr/share/keyrings/caddy-stable-archive-keyring.gpg
sudo chmod o+r /etc/apt/sources.list.d/caddy-stable.list
sudo apt update
sudo apt install caddy
- Replace the contents of
/etc/caddy/Caddyfilewith two lines inside a site block: your hostname, for exampleha.example.com {, thenreverse_proxy localhost:8123and a closing}. - Check the service with
systemctl status caddy, then apply the file withsudo systemctl reload caddy. If something else already listens on 80 or 443,sudo ss -ltnpshows what it is. - Through your tunnel, open Settings > System > Network. In the HTTP server section turn on trusting
X-Forwarded-Forand add127.0.0.1and::1as trusted proxies; without this, Home Assistant blocks proxied requests by design. Turn on IP banning while you are there. - Set the Home Assistant URL on the same page to your
https://address, then sign in through it from your phone. - Under your user profile, open Security and enable the authenticator app in the multi-factor authentication section.
Would you rather nothing faced the internet at all? Run a mesh VPN instead and leave only SSH open; our page on hosting your own NetBird server covers that route, and the same tunnel can carry traffic back to devices at home.
Backups and updates without nasty surprises
Set up automatic backups under Settings > System > Backups and download the emergency kit when asked: its encryption key is the only way to restore them. On Container a backup holds your settings and, if you tick it, history; apps, media and network storage are OS-only. The files land in the backups folder of the config directory, here /opt/homeassistant/config/backups.
- Copy that folder off the server regularly, for example from your own computer with
scp -r root@YOUR_SERVER_IP:/opt/homeassistant/config/backups ./ha-backups. The project recommends a copy on another system and ideally one off-site. - To restore onto a fresh machine, choose Upload backup on the welcome screen and give it the key from the emergency kit.
- A new release ships every month. Take a backup first, then from
/opt/homeassistantrundocker compose pullanddocker compose up -d; Compose recreates the container only when its image or settings changed. - Patch the server itself with normal system updates.
Incoming traffic to a Cloud VPS is free; only what the machine sends counts toward its monthly allowance.
When a box at home is the better choice
Keep Home Assistant at home if most of your devices are local. Zeroconf discovery scans the network Home Assistant sits on, so a server in New York will not find the lights on your shelf. USB sticks for Zigbee and Z-Wave plug into the machine running the software. For Silicon Labs Zigbee coordinators, the integration's own docs say a connection over Wi-Fi, WAN or VPN is not recommended, because the radio needs a stable serial link.
A remote server earns its place when your home leans on cloud-connected devices, when you want automations that keep running while the house is offline, or as a hub that other sites report into. A common split is a small box at home for the radios and local devices, and a rented server for the parts that face the internet, such as an MQTT broker you lock down yourself, since Container cannot run the Mosquitto app.
Questions people ask
- Can Home Assistant OS run on a Cloud VPS?
- No. A Cloud VPS installs Ubuntu, Debian, AlmaLinux or Rocky Linux only, so run Home Assistant Container there. For Home Assistant OS and its apps, use a whole server with Proxmox VE and run the OS as a virtual machine with UEFI, 2 vCPUs and 2 GB of memory or more.
- Will my Zigbee or Z-Wave devices work with a remote server?
- Not directly. A USB radio stick has to be plugged into the machine running the software, and while network-attached coordinators exist, the Zigbee integration's docs advise against running some of them over a WAN or VPN link. Keep a small box at home for local radios and use the remote server for cloud-connected parts.
- Is it safe to put Home Assistant on the public internet?
- Only with care. Keep port 8123 closed, put an HTTPS reverse proxy such as Caddy in front, trust only that proxy, turn on IP banning and multi-factor authentication, and create the owner account before the site is reachable. A VPN with no public web port is safer still.
- What do I lose with the Container install?
- Apps. Anything you would have added as an app, such as an MQTT broker or a file editor, you run as your own container or service. Backups still work, but they cover settings and optional history rather than the whole system, and you update the image yourself.
- What if the server stops answering?
- Open the console from your dashboard to see the screen, or restart the machine there. If nothing else works, reinstall it and restore your latest Home Assistant backup. People are on chat and phone at any hour if you get stuck.