Video website bandwidth calculation

Published: 2019-06-19

```html

Term Explanation

Bandwidth:   It is transmission rate, referring to the maximum number of bytes transmitted per second (mbps/kbps), i.e., how many megabytes are processed per second. High bandwidth means the system has high processing capacity

Bitrate:     It is the number of data bits transmitted per unit time during data transmission, and the unit we generally use is kbps, i.e., kilobits per second



Relationship between Frame Rate, Bitstream and Resolution

Formula:

Bandwidth / (bitstream * 8) = number of concurrent online users

File size = time X bitrate /8 



Example: A website has a video, size 5.86M  playback time 3 minutes 7 seconds

1. The bitstream corresponding to the file is

    5.86 * 1024 * 1024 * 8 / (3*60+7)  = 262872.96 bps


2. Number of users supported by 10M dedicated bandwidth 

   10 * 1024 * 1024 / 262872.96 = 39.89    #Equivalent to the video file on 10M bandwidth supporting 39.89 concurrent viewers


3. How much bandwidth is needed to support 100 concurrent viewers

    262872.96  * 100 / 1024 * 1024 = 25.07mbps  #Equivalent to needing to purchase 25M bandwidth


The actual production environment is affected by other factors; the actual number of online users will be lower thanthe theoretical value; actual bandwidthusage is subject to actual conditions. It is recommended to place videos on third-party websites and call video links via external links.


```