On the next page I'll explore how the x265 preset determines encode times, file sizes and quality, but basically you want to leave it on Medium for the best balance of encode time and file size. Then, select an x265 preset of Medium by adjusting the slider down from the default Ultrafast setting.Make sure framerate is set to 'same as source' and that the 'Use advanced video tab instead' box is unchecked. In the Video tab you'll want to select some specific settings.If you want to remove noise or grain from a source, setting Denoise to hqdn3d with a custom preset of 1:1:4:4 is a solid choice. If a TV show is interlaced, for example, it's a good idea to set Decomb to Fast as this will only deinterlace frames that are visibly interlaced. In the Filters tab, you'll only want to modify these settings where necessary, leaving everything else 'off'.If, however, you have a 21:9 video encoded in 16:9, the cropping feature will automatically crop out the black bars at the top and bottom.
Sometimes it will erroneously crop out a few pixels on any side, but you can address this by switching to custom with 0 set in every location box. Also check to make sure the automatic cropping feature has detected the correct settings.
While I'll be exploring other encoding options later in this article, this page will give you step-by-step instructions on how to set Handbrake to encode small, high-quality HEVC files. How to Encode HEVC: Handbrake Settings to Use