Cameras are the easy part of a home NVR, you can order them in a minute. The hard part is a server that keeps watching without turning into a space heater. This guide lists what to decide first.
The short answer
Frigate is a free NVR (network video recorder) that runs as a Docker container and checks camera pictures for people, cars and animals on your own hardware. Four decisions shape the build: the detector that runs the object recognition, the video decoding that eats most of the CPU, cameras with a usable low-resolution substream, and disk space for the recordings. Our assessment for a new build: a small x86 PC with a 6th-generation or newer Intel processor and its integrated graphics running OpenVINO, wired PoE cameras with a substream, and a local disk sized with the formula below. The Frigate documentation no longer recommends a Google Coral for new installations [1].
How it works
- Four jobs for the hardware. Frigate decodes the camera stream into pictures, looks for motion on the CPU, sends the moving regions to a detector, and writes the original camera stream to disk without re-encoding it [6][9]. A detector is a chip or a program that runs the recognition model quickly. It does not help with decoding. The documentation calls video decoding one of the most CPU-intensive tasks. The load grows with resolution and frame rate: a 4K stream at 30 fps needs roughly four times the processing power of 1080p at the same frame rate, and doubling the frame rate doubles the work [9].
- Size by simultaneous activity, not by camera count. The planning page sorts setups by how many cameras see motion at the same time. One to six cameras with occasional motion are fine with a single entry-level accelerator. Six to twelve cameras with overlapping motion need more. Twelve or more cameras, or very busy scenes, call for several accelerators or a discrete GPU [2]. Our reading: a quiet driveway and a hallway are a small job, a street view with traffic is not.
- Pick the detector. The hardware page lists many options. The table "Detector options at a glance" below the list shows the ones homelab builders meet most often, with the inference times the page prints. The times come from different models and are not comparable across rows [1]. The docs give a rule for capacity: a detector with 10 ms inference time tops out at 1000 / 10 = 100 detections per second [1]. For the N100 row that is 1000 / 15, about 66 per second (our arithmetic). The docs also note that a single Coral handles many cameras for most users [1].
- Decoding and the CPU. Frigate needs a CPU with AVX and AVX2. Celeron and Pentium models before the 2020 Tiger Lake generation typically lack AVX [2]. Use the integrated GPU for decoding. For Intel the docs recommend
preset-vaapifor generations 6 to 12 andpreset-intel-qsv-*for generation 13 and newer. There is no CPU fallback: if the setting is wrong, check the logs for errors [5]. RAM: 4 GB is a basic minimum, 8 GB if you use enrichments such as face or licence plate recognition, 16 GB is recommended for eight or more cameras [2]. - The box itself. The docs recommend Docker on bare-metal Debian-based Linux. A VM on Proxmox or ESXi is "not recommended", though some users succeeded with Proxmox. Windows is not officially supported [7]. The docs author prefers a mini PC with two network ports, so the cameras can live on a private network that cannot reach the internet [1]. Our guide on mini PCs for the homelab covers the box choice. One security note: the releases 0.18.1 and 0.18.2 list security fixes, among them remote code execution reports [11]. Keep Frigate updated and do not expose it to the internet. Port 8971 is the authenticated UI, port 5000 is unauthenticated and the docs ask you to limit access to it [7].
- Cameras. H.264 video with AAC audio is the most compatible choice. Cameras with several substreams let you use one low-resolution stream for detection and the full-resolution stream for recording [1]. The detect stream is the only one Frigate decodes. Its default of 5 fps is right for almost every camera, and 10 fps is the recommended maximum [3]. Pick the detect resolution so that the objects you care about fit into the 320x320 area of the model. Higher resolutions add no accuracy, unless objects are very small in the frame [3]. The docs author suggests 15 fps for the recording stream and the same aspect ratio on both streams [3]. Wi-Fi cameras are not recommended because their streams are less reliable. For Reolink the docs suggest 5 MP or less [1]. A go2rtc restream lets Frigate and the live view share one connection to the camera [4]. H.265 saves space, but browser support is narrower, and the pages list different browser versions. Test it on your own devices first [3][6].
- Brand lists are opinions. The hardware page names Dahua, Hikvision and Amcrest, in that order, and says larger sensors beat higher resolution at night. The page contains affiliate links and states that the author earns a commission [1]. Treat the list as one experienced user's view and check the criteria above on the datasheet of any camera you consider.
- ONVIF in plain words. ONVIF is an industry standard that lets IP cameras and recorders talk to each other regardless of brand. Profile S covers basic video streaming, Profile T adds H.264 and H.265 encoding, imaging settings, motion and tamper events, metadata and two-way audio [12][13]. Conformance belongs to a specific product and firmware version, and the ONVIF site lists conformant products [14]. In Frigate, ONVIF does two jobs. The Add Camera wizard can ask the camera for its stream addresses (the ONVIF port is usually 80 or 8080), and ONVIF carries PTZ commands (pan, tilt, zoom). The video itself still arrives over RTSP [4]. Some cameras need a separate ONVIF account and some reject the login if their clock is off, so run NTP on camera and server. For automatic tracking the camera must support relative PTZ movement, and some cameras claim support without delivering it [4].
- PoE and the camera network. One cable for power and video is the main reason to prefer wired PoE cameras. Read the PoE class and power draw on the camera datasheet, add the values, keep reserve, and compare the total with the switch budget. Our PoE switch guide shows the maths. Keep cameras in their own VLAN or on a second network port, as the docs suggest, and see our VLAN guide for the setup.
- Storage: bitrate decides. Frigate writes recordings straight from the camera stream, so the bitrate of the stream you assign to
recordis the bitrate on disk [6]. Convert it: GB per day = Mbit/s x 86,400 / 8 / 1,000 (our arithmetic, decimal GB). The bitrates below are assumptions for illustration, not measurements. Read your real value from the camera settings or from the estimated bandwidth in Frigate's Add Camera wizard [4]. The table "Disk space at a glance" below the list shows the result. Continuous recording is off by default. Frigate can keep continuous footage for a few days, motion footage longer, and footage around alerts and detections longest. The docs show three presets: keep everything for 3 days, keep only motion, or keep alerts only [6]. How much a motion-only setting saves depends on your scenes, so the saving is unknown until you measure it. - Disks and network storage. The docs consider SSDs fine for home NVR use and say the old wear-out worry is largely outdated, and they name surveillance-rated hard drives as a cost-effective choice for long retention. Network storage works, but local disks are recommended, and a NAS needs at least Gigabit Ethernet and enough write capacity [2]. Our addition: check SMART values after a few months either way. Plan for more than the recordings: snapshots, previews, exports (which retention never deletes), the database and model files take space outside the recordings total, and an ext4 disk reserves about 5 percent for root by default [6]. Use a tmpfs mount for
/tmp/cache, as the compose example in the docs does [7]. - Home Assistant. The Frigate integration for Home Assistant needs an MQTT broker, and both Frigate and Home Assistant must use the same one. You install the integration through HACS. It is not the same thing as the Frigate add-on or app [10][7]. For the Home Assistant host see our guide on Home Assistant hardware.
- Privacy: ask the right people. A camera records people. Whether and how data protection law applies to your setup, for example with a view of a street, a neighbour's garden or shared stairs, is a legal question we do not answer. Starting points are the European Data Protection Board guidelines on video devices [15] and, in Germany, the overview of the Federal Commissioner for Data Protection and the list of state authorities [16][17]. For your own case, ask your state authority or a lawyer.
Detector options at a glance
| Detector | Runs on | Example time from the docs [1] | Note |
|---|---|---|---|
| OpenVINO | Intel iGPU (6th generation and newer), Intel Arc, Intel NPU | Intel N100: ~15 ms (MobileNetV2). Iris Xe: ~10 ms. Intel NPU: ~6 ms | N100 and HD 530 can run only one detector instance |
| Hailo-8 / Hailo-8L | M.2 module, Raspberry Pi 5 AI Kit | Hailo-8L ~11 ms, Hailo-8 ~7 ms (YOLOv6n) | Raspberry Pi OS Bookworm needs a driver swap [7] |
| Nvidia GPU (ONNX) | Driver 545 or newer, compute capability 5.0 or higher | GTX 1070: 16 ms, RTX 3050: 10 ms (YOLOv9 s-320) | Highest power draw of the group (our assessment) |
| Google Coral | USB or M.2 | Not listed as a time in the table | No longer recommended for new installs, except for very low power needs |
Disk space at a glance
Assumed bitrates, four cameras, seven days of continuous footage (our arithmetic, not measurements):
| Assumed bitrate | Per camera and day | 4 cameras, 7 days continuous |
|---|---|---|
| 2 Mbit/s | 21.6 GB | 604.8 GB |
| 4 Mbit/s | 43.2 GB | 1,209.6 GB |
| 8 Mbit/s | 86.4 GB | 2,419.2 GB |
A sample build, not our system
This is an example calculation. We make no statement about camera or NVR setups in our own homelab.
Assume four wired PoE cameras, each with a 4 Mbit/s main stream and a 1280x720 substream, 7 days of continuous footage, and an Intel mini PC with 16 GB RAM.
- Disk: 4 x 43.2 GB x 7 = 1,209.6 GB. With about 5 percent reserved, a 1.27 TB usable minimum. We would buy a 2 TB disk and keep some headroom.
- Detector: OpenVINO on the integrated GPU. If the box needs about 15 ms per detection, it can do roughly 66 per second. Four cameras at 5 fps produce at most 20 frames per second, and a frame can contain several motion regions, so the real load lies somewhere below the sum. Measure it in Frigate's system page after a week.
- Decoding: four 720p substreams at 5 fps, with
hwaccel_args: preset-vaapi.
A compose file, following the structure in the docs [7]. Replace paths and the device for your hardware, and calculate shm_size with the calculator in the docs for your version. The default of 64 MB is too small for most setups. "Bus error" messages are the symptom.
services:
frigate:
container_name: frigate
restart: unless-stopped
stop_grace_period: 30s
image: ghcr.io/blakeblackshear/frigate:0.18.2
shm_size: "512mb"
devices:
- /dev/dri/renderD128:/dev/dri/renderD128
volumes:
- /etc/localtime:/etc/localtime:ro
- /srv/frigate/config:/config
- /srv/frigate/storage:/media/frigate
- type: tmpfs
target: /tmp/cache
tmpfs:
size: 1000000000
ports:
- "8971:8971"
- "8554:8554"
environment:
FRIGATE_RTSP_PASSWORD: ${FRIGATE_RTSP_PASSWORD}The tag 0.18.2 appears on the release page [11], the docs use stable. In config.yml, one camera uses the substream for detect and the main stream for record, and the recording section follows the docs preset for "only motion" [4][6]. The stream paths are placeholders, because every brand uses its own.
ffmpeg:
hwaccel_args: preset-vaapi
cameras:
driveway:
ffmpeg:
inputs:
- path: rtsp://viewer:{FRIGATE_RTSP_PASSWORD}@10.0.10.10:554/<substream-path>
roles:
- detect
- path: rtsp://viewer:{FRIGATE_RTSP_PASSWORD}@10.0.10.10:554/<mainstream-path>
roles:
- record
detect:
width: 1280
height: 720
record:
enabled: True
motion:
days: 3
alerts:
retain:
days: 30
mode: motion
detections:
retain:
days: 30
mode: motionThe detector section is missing on purpose. The syntax changed between versions: the stable docs we read use detectors: with a model: block, while the development docs on GitHub list a models: block with devices. Copy the OpenVINO block from the documentation of the version you install [8].
Checklist
- Count the cameras that can see motion at the same time, and use that number, not the total, to choose the detector.
- Choose a detector from the current hardware page, and skip a Coral for a new build.
- Check that the CPU supports AVX and AVX2, and that the integrated GPU can decode your camera codec.
- Pick cameras that offer H.264, a second low-resolution stream and a wired connection.
- Search the ONVIF conformant products list for each camera model, and test the ONVIF login before you mount anything.
- Add up the PoE power from the datasheets and compare it with the switch budget plus reserve.
- Calculate the disk size with Mbit/s x 86,400 / 8 / 1,000 for each recorded stream, and add reserve.
- Mount
/tmp/cacheas tmpfs and setshm_sizefrom the calculator for your version. - Put the cameras in their own VLAN or network, and keep Frigate off the open internet.
- Ask your state data protection authority or a lawyer before you point a camera at anything outside your own property.