YouTube has long sought to remake television for the web, and now it has an Emmy to show for it. The National Academy of Television Arts & Sciences said today that the Google-owned video service has won a technical Emmy for its personalized video recommendations. The Emmy honors the computer science that powers YouTube’s recommendation algorithm, which suggests clips to watch based on a person’s viewing history, popular videos, and other signals.

The Emmy, which will be presented in January at the Consumer Electronics Show in Las Vegas, recognizes YouTube’s efforts to guide its 1 billion monthly users through the world’s largest video library. "What’s remarkable is that the biggest problem we hear from viewers is they can’t find anything to watch on YouTube," said Cristos Goodrow, an engineering director at the company. "Our job on the discovery team is to help solve that problem for the viewers."

The Emmy win comes amid a broad push to make YouTube feel more like television. Google has invested hundreds of millions of dollars in creating professional-quality channels in a campaign to attract TV-scale advertising revenues. The company has simultaneously mounted an effort to increase the number of channels users subscribe to, with the idea that they will begin watching the site for hours at a time instead of minutes. But while the company says that subscriptions and overall viewership are increasing, YouTube has yet to produce a mainstream hit on the level of Netflix’s House of Cards or Orange is the New Black.

YouTube won its first Emmy for the quality that makes it so unlike television

It’s notable, then, that YouTube won its first Emmy for the quality that makes it so unlike television: an algorithm that makes the site feel deeply personal and combs through a massive collection of content to find the videos that will capture your attention for a few minutes longer. The channels may be getting all the attention these days, but as anyone who has fallen into the wormhole of related videos can attest, the recommendation algorithm might still be YouTube’s most valuable asset.

Serious efforts to recommend related videos to YouTube users began in 2008, three years into the site’s existence and two years after Google acquired it. That’s when YouTube began suggesting other videos for users to watch, both on its home page and on the right-hand side of individual video pages. By the end of 2008, the algorithm was responsible for "hundreds of thousands of hours" of additional video viewing each day, Goodrow says. Today, he says, that number is in the millions.

Along the way, YouTube learned some surprising lessons about what makes for a good algorithm. For starters: suggesting the videos most closely related to the one a person is already watching actually drives them away. "If we show what our algorithms think is the best possible match all the time, they get bored pretty rapidly," says Hector Yee, a software engineer at YouTube who works on building the algorithm. "Users like a variety of topics."

Sometimes, the "related" videos a person is most likely to click aren’t related at all, says Su-Lin Wu, a software engineer. As the team experimented, it found that we often like to leap from subject to subject, as long as those leaps seem personalized to our individual interests.

Goodrow says YouTube’s chief advantage in building its algorithm is the huge amount of data it has about what people like. YouTube gets both explicit signals, such as when a viewer gives a clip a thumbs up, and more implicit ones, such as which videos they watch all the way through. Taken together, the data builds a picture of what a visitor is likely to click on.

"It kind of boils down to accounting."

"We can talk about the machine learning techniques that we use, or the amount of data, but in a way it kind of boils down to accounting," Goodrow says. "The videos that show up on the right-hand side, the reason they do is because many people before you have watched those videos you’re seeing on the right after the one you just watched. To some extent we’re just keeping track of that, and using the fact that all those other people did that before you, to say we’re pretty sure the next person who watches this video might also be interested in those things."

The challenge for YouTube is translating that accounting into the experience they keep saying they want to build: one that lets the viewer lean back, enjoying videos for 30 minutes or an hour at a time without having to click around for something else to watch. Goodrow says the algorithms his team builds can help with that. "I think our recommendations could be much, much better than they are today — that’s what keeps us focused," he says.

But the data can only do so much. Creators have to do their part, too. "It’s not just how good you can make the recommendations," Goodrow says, "We’re only as good as the videos that get uploaded to YouTube."