Skip to content

CCTV Storage and Bandwidth Planning: Bitrate, Retention, and Codec Selection

Every IP camera generates data continuously. A system with 100 cameras recording at high resolution can consume terabytes of storage per week — or a fraction of that, depending on codec choice, bitrate configuration, and retention policy. This guide provides the formulas and methodology for calculating storage requirements, selecting between H.264 and H.265 codecs, sizing network bandwidth, and planning recording infrastructure that meets retention obligations without exceeding budget.

Open the free CCTV Design Tool →

1. The Storage Equation

Storage is a function of bitrate, time, and camera count. The fundamental formula is straightforward:

Storage (GB) = Bitrate (Mbps) × 3600 × Retention (hours per day) × Days × Cameras ÷ 8 ÷ 1000

This formula gives total storage in gigabytes. The key variable is bitrate — the amount of data each camera generates per second. Bitrate is influenced by resolution, frame rate, codec, and scene complexity.

1.1 Worked Example

A 50-camera system with each camera recording at 4 Mbps, for 12 hours per day, with 30-day retention:

4 × 3600 × 12 × 30 × 50 ÷ 8 ÷ 1000 = 3,240 GB (3.24 TB)

At the same settings with H.265 encoding (assuming 40% bitrate reduction), the requirement drops to approximately 1.94 TB — a saving of 1.3 TB or roughly 40%.

2. Codec Comparison: H.264 vs H.265

The choice of video codec has the single largest impact on storage requirements after camera count and resolution. H.265 (HEVC) delivers equivalent visual quality to H.264 (AVC) at significantly lower bitrates, but the savings depend on scene complexity and camera configuration.

Parameter H.264 (AVC) H.265 (HEVC)
Compression efficiency Baseline 40–50% more efficient than H.264
Typical 1080p bitrate 4–6 Mbps 2–3 Mbps
Typical 4MP bitrate 6–8 Mbps 3–4 Mbps
Typical 4K bitrate 12–16 Mbps 6–8 Mbps
Decode support Universal — all browsers, NVRs, clients Most modern NVRs; limited browser support
Transcoding cost None Additional processing for multi-platform playback
Recommended for Small systems, maximum compatibility, edge recording Large systems (>20 cameras), bandwidth-constrained networks, long retention

2.1 Variable Bitrate vs Constant Bitrate

Most IP cameras support both CBR (constant bitrate) and VBR (variable bitrate). CBR reserves a fixed amount of bandwidth regardless of scene activity, which simplifies network planning but wastes storage during quiet periods. VBR allocates more data during motion and less during stillness, typically achieving 20–30% storage savings for the same perceived quality.

For most CCTV applications, VBR with a configured maximum bitrate provides the best balance of quality and efficiency. Set the maximum bitrate to the value you would use for CBR, and let the encoder reduce data during quiet periods.

Choose your codec before you size your storage.

Switching from H.264 to H.265 on a 100-camera system can save 5–10 TB of storage and reduce network bandwidth by 40%. Factor codec choice into your design from day one — retrofitting is expensive.

3. Network Bandwidth Planning

Every camera not only writes to storage but also streams across the network. The aggregate bandwidth of all cameras must not exceed the capacity of the network infrastructure, or footage will be lost.

Total bandwidth (Mbps) = Per-camera bitrate × Number of simultaneous streams

The number of simultaneous streams depends on the recording architecture:

  • Centralised NVR: Each camera streams to one NVR = 1 stream per camera
  • Distributed recording: Each camera records to an SD card or edge device = 0 network streams for recording, but additional streams for remote viewing
  • Multi-stream: If cameras send a primary stream (recording) and secondary stream (monitoring), plan for the total of all active streams

3.1 Switch Sizing

A 48-port PoE switch with a 1 Gbps uplink can support approximately:

Camera Count Per-Camera Bitrate Total Bandwidth Switch Requirement
16 cameras × 4 Mbps 4 Mbps (H.264 1080p) 64 Mbps 1 Gbps uplink — comfortable
32 cameras × 6 Mbps 6 Mbps (H.265 4MP) 192 Mbps 1 Gbps uplink — adequate with headroom
48 cameras × 8 Mbps 8 Mbps (H.264 4MP) 384 Mbps 1 Gbps uplink — approaching limits
48 cameras × 12 Mbps 12 Mbps (H.264 4K) 576 Mbps 10 Gbps uplink recommended

Rule of thumb: keep aggregate camera bandwidth below 50% of the uplink capacity to allow for burst traffic, VBR peaks, management overhead, and client viewing streams.

4. Retention Policy: How Long to Keep Footage

Retention requirements are driven by a combination of legal obligations, client expectations, and operational needs. They directly determine total storage capacity.

Industry / Region Typical Minimum Retention Reference
UK — general commercial 30 days ICO CCTV Code of Practice
UK — retail / high-risk 31–90 days Police / insurer recommendation
UAE / GCC 30–90 days SIRA / local authority requirements
EU (GDPR) As short as possible; 24–30 days typical GDPR Art. 5(1)(e)
US — financial 90–365 days SEC Rule 17a-4, PCI DSS
US — general No legal minimum; 30–60 days typical Client / insurer policy
Critical infrastructure 90–365 days Site-specific security policy

4.1 Storage Scaling by Retention

The storage impact of retention is linear. Doubling retention doubles storage. The 50-camera system that requires 3.24 TB for 30-day retention would require:

  • 60 days: 6.48 TB (H.264) / 3.89 TB (H.265)
  • 90 days: 9.72 TB (H.264) / 5.83 TB (H.265)
  • 365 days: 39.42 TB (H.264) / 23.65 TB (H.265)

Size your storage for the retention you actually need, not the retention you might want someday.

Over-provisioning storage wastes budget. Under-provisioning causes early footage overwriting before the retention period expires. Calculate your requirement using the storage equation, then add 15–20% headroom for VBR peaks and system overhead.

5. Recording Architecture Options

The recording architecture determines how footage is captured, stored, and retrieved. Each approach has different bandwidth, storage, and resilience characteristics.

5.1 NVR (Network Video Recorder)

The most common approach for medium to large installations. A dedicated NVR appliance receives camera streams over the network and writes them to internal storage. NVRs are typically sized by camera count (16, 32, 64, 128 channels) and total storage capacity.

5.2 Server-Based Recording

A server running VMS (Video Management Software) records to direct-attached or network-attached storage. This approach offers greater flexibility in storage configuration and scalability but requires more technical expertise to maintain.

5.3 Edge Recording

Cameras with SD card slots record locally, eliminating the need for dedicated recording infrastructure. Suitable for small installations or as a failover mechanism for larger systems. Bandwidth requirements are minimal for recording but increase significantly for remote viewing.

6. Bandwidth Optimisation Techniques

  • Adaptive bitrate streaming — reduce secondary stream quality for remote viewing while maintaining full quality on the recording stream
  • Motion-triggered recording — record at full bitrate only when motion is detected; reduce to minimum quality during stillness (saves 30–60% storage)
  • Schedule-based recording — record at full quality during business hours; reduce resolution or frame rate during off-hours
  • Region of Interest (ROI) encoding — allocate more bitrate to the important areas of the frame and less to static backgrounds
  • Sub-stream recording — record a lower-resolution stream for long-term archival and a high-resolution stream for short-term evidence

Design your network and storage together.

Storage sizing is meaningless without corresponding bandwidth planning. A system that stores enough footage but saturates the network will lose frames during peak traffic — exactly when incidents are most likely to occur. Use the free CCTV Design Tool to plan camera placement, then size your network and storage using the formulas in this guide.

Plan your CCTV system →