Compressing Video Files for Web (with HandBrake)

When uploading a video to the web, it's best to compress the videos so to maintain a balance between performance and quality.  Bandwidth speeds, CPU specs, and other factors will affect video performance and will vary between locations.  It may take some trial and error to get the right settings for your video.

Keep in mind that videos will have to load and play properly at the training locations with the worst connection speeds.

This article will cover:



Using Handbrake to Compress Your Videos

Handbrake is a free program that makes video compression easy. 

You can download Handbrake from:  https://handbrake.fr/


1. Drag and drop your video into Handbrake to get started.


2. On the Summary tab:

  • Make sure the 'Web Optimized' checkbox is checked.  
  • Choose the 'MP4' Format, if it's not already selected.
    (Note: you can change the default for this in Tools > Preferences > Output Files)


3. On the Dimensions tab:

  • Set 'Anamorphic' to 'None'.
  • Make sure 'Keep Aspect Ratio' is checked
  • Resize the video by typing into the Width or Height fields.
    (Note: This is one of the best ways to keep file sizes and bandwidth usage down.  You usually won't need videos larger than 1024 width.)


4. On the Video tab:

  • Set the Framerate (FPS) to 'Same as source'.
  • Set the Constant Quality to 25 RF. Typically, we keep this number between 20 and 30 RF. 
    • This is the best setting to tweak when you are trying to find the right balance of quality vs. file size vs. bandwidth.  


5. On the Audio tab:

  • First, click the down arrow on the right side to see all the settings.
  • Then, use the following settings.  (If you notice a huge drop in audio quality, you can probably increase the Samplerate or Bitrate a little to increase the quality.)
    • Mixdown: Mono
    • Bitrate: 96
    • Samplerate: 22.05


6. (Optional) If your video is really long, it might make sense the split the video up into multiple smaller videos and use Video Chapters in Cognition to tie them back together into one video.

  • You can use the Range settings at the top, to split this up into smaller videos.  We've found that the Frames option seems to be the most accurate.


7. Click Start Encode to start processing the video.

  • Once the encoding is complete, you will get see "Queue Finished" at the bottom-left. 
  • Check the file size and see if it's manageable.  Most videos should be under 10MB.
  • Watch the video locally for quality and accuracy before uploading.
  • If anything seems wrong, try adjusting the settings and clicking Start Encode again. 
    • Note: If you do end up re-encoding, make sure to do so from the original version of the file, not the compressed version.



Best Practices for eLearning Videos on the Web

  • Videos should be under 10MB.
  • Most videos should be 1024 width or less.
  • If a video is longer than 10 minutes, you might consider splitting the video into multiple smaller videos and using Video Chapters in Cognition.
  • Using 'Web Compressed' in Handbrake puts the video codec information at the beginning of the file, which allows the video to start playing sooner.  If you don't check this checkbox, it will have to wait until the entire video has loaded for the student before it's allowed start playing.
  • You can save your common settings in Handbrake as a Preset, which allows you to quickly process videos the same way. 
  • Once you've gotten used to using Handbrake, you can batch process multiple videos at the same time by copying them into a folder and using the Folder Scan option along with a Preset.  (You may still need to adjust the Dimension of each video when using this method.)