I have my html and body set to 100% height, and a background image set on body, which gets cut off when scrolling down, as shown below.

However, YouTube has 100% height on html and body, and a background on body, and it stretches to the full height of the content. How can I achieve this?
If the only reason you put the 100% height is for the background (as one of your comments seems to suggest), then just change that to
min-height: 100%and you should have no issues. You will have 100% height on short pages, but expand to as much as you need on longer pages.