Why do YouTube views freeze at 301?

Brief Summary

This Numberphile video explains the mystery behind why YouTube view counters often freeze at 301 views. It features an interview with Ted Hamilton, a YouTube Analytics product manager, who explains the technical and historical reasons for this phenomenon. The video covers how YouTube defines a "view," the process of counting views across multiple servers, the statistical verification process for views, and the specific code that causes the 301 freeze.

  • YouTube view counters freeze at 301 due to a historical coding quirk and a statistical verification process.
  • YouTube validates views to prevent bots and misleading content from inflating view counts.
  • The "301 freeze" is a result of a "less than or equal to" condition in the code that determines when to stop incrementing the view count before verification.

Intro: The Mystery of the 301 Freeze

The video addresses the common question about why YouTube view counters freeze at 301. Many viewers have noticed that after a video is uploaded, the view count rises quickly but then stops at 301 for a period before resuming normal counting. Brady Haran interviews Ted Hamilton, a product manager for YouTube Analytics, to explain the reasons behind this phenomenon.

What Counts as a View?

Ted Hamilton explains that a "view" on YouTube is defined as a video playback requested by an actual user who intends to watch the video and has a good user experience. YouTube considers views as a currency and puts significant effort into eliminating "counterfeit views." The video hints that the concept of counterfeit views is related to the 301 freeze.

Counting Views Across Multiple Servers

The video explains that YouTube videos are cached in multiple locations around the world to ensure efficient delivery. When a user watches a video, their request is served by a local server, which also logs the view. These logs are periodically collected and aggregated in a central location for counting.

The Statistical Verification Process

Ted Hamilton explains that once a video reaches around 300 views, YouTube initiates a statistical verification process to ensure the views are legitimate. This process involves verifying that the views are not from bots or misleading content. The verification process takes time, which is why the view counter freezes. YouTube moves from incrementing views one by one to incrementing in batches after verification.

Why 301? The Arbitrary Threshold

The video addresses why the view counter freezes specifically at 301. Ted Hamilton admits that the decision to set the threshold at approximately 300 views was somewhat arbitrary. The goal was to differentiate between casual home videos and more popular videos that require scrutiny. The exact formula used to arrive at the 300 threshold is not known.

The Coding Quirk: Less Than or Equal To

The video reveals that the view counter freezes at 301 due to a coding error. The code uses a "less than or equal to" condition instead of a "less than" condition. Specifically, the code reads: "If the view count is less than or equal to 300, then increment the view count." This allows the counter to reach 301 before the verification process begins and the counter freezes.

Simultaneous Updates and Variable Freezing Points

The video explains why the view count sometimes freezes at numbers other than 301, such as 302, 305, or 310. This is due to simultaneous updates from different servers around the world. If multiple views come in at the same time while the view count is still less than or equal to 300, they can all be added before the door is shut, resulting in a freezing point higher than 301.

Likes vs. Views and Future Content

Ted Hamilton notes that the discrepancy between likes and views (e.g., 2,000 likes but only 300 views) is because likes are not subjected to the same rigorous verification process as views. The video concludes with Brady Haran mentioning that he has additional footage from his interview with Ted Hamilton, which will be uploaded to Numberphile in the future.

Summarize any YouTube video in seconds

Get summaries like this one for any video, in your language, with the free Summ app.

Download on the Apple Store
Get it on Google Play

Transcript

Full transcript of “Why do YouTube views freeze at 301?”. Click a timestamp to open the video at that moment. Need another video? Use the YouTube transcript generator.

0:00 BRADY HARAN: I want to deal with a number that must be the most requested so far on Numberphile, and that is 301. Now, for those of you who don't pay much attention to the YouTube view counters, you might wonder what the big deal is with 301, and let me tell you. When a new video is uploaded, and if it's quite a popular one, you'll quickly see the view counter rise and rise and rise, and then it will get to 301, and it will freeze. And it will stay on 301 for a day, maybe half a day, and then it will start counting to higher numbers as usual. Now, a lot of people have been very mystified by this, and have asked us to check it out. TED HAMILTON: I'm Ted Hamilton, I'm a product manager for YouTube Analytics. BRADY HARAN: So there you go. I've got in touch with the people who actually count the YouTube views.

0:46 TED HAMILTON: That is correct. Well, we actually have the computers do it. We don't count them ourselves, but yes. BRADY HARAN: So before we get to this whole 301 malarkey, what is a view on YouTube? I've always wondered. is someone just pressing play counting as a view? TED HAMILTON: Well, that's actually a bit of a YouTube secret. A view should be a video playback that was requested by an actual user who got what they were intending to get and had a good user experience. We think of views as a currency, and therefore we have to make a significant effort to eliminate counterfeit views, if you will. BRADY HARAN: Now, I know that all sounds a bit mysterious, and we will come back to it later on in the video, but let's crack on with this 301 figure. And you're going to find out counterfeit views actually have a bit to do with it.

1:33 But the next thing we need to realize is when you watch any video, like this one for example, you're probably not all watching it from the same server. It gets distributed all around the world. TED HAMILTON: So there is the original, which you will have uploaded. Or I guess by the time you are watching this, have already uploaded. Then this gets, what do you call it? Cached in different locations, so that when you make a request for a video, it doesn't need to travel all the way from London over to California and say OK, send me back all of these bytes way back here. BRADY HARAN: So with multiple copies of the video all around the world, counting the views starts to get a little bit more complicated. TED HAMILTON: Here's you at your computer watching the video. If you make a request to this server, this server is going to give you the video, right? And at the same time, this server is going to write a

2:19 little message to a log. It's just one line in a log. Every once in awhile, we collect all of these logs. So we'll ship this thing in from central Europe, or whatever into the central log collection area, aggregate them all together, and then go through and count them up. BRADY HARAN: Well OK, that seems simple enough, but it doesn't explain why the view counter freezes. TED HAMILTON: Views, as mentioned, are a currency. When you have a video with a very small amount of views, then you don't need to be too careful about what that view was. However, once it gets to be above 300 and beyond, this currency we really need to verify and make sure that the number is what it purports to be. So this means that we have to go through a statistical verification process, and that statistical verification

3:06 process actually takes some time. And thus we go from incrementing one by one to then saying, OK, now we're incrementing in batch, and all of these views that have been added on have been verified by YouTube to be real views. We are preventing things like bots to go in and add a bunch of views to a video. Or we are preventing something that may have perhaps misled someone into watching a video. Say you had a title that was completely misleading, and a thumbnail that was completely misleading, and people actually went on there and just viewed for a few seconds, and then left. If you see that enough times, it a fair enough indicator that something was wrong there, so that we might not

3:52 authorize all of those to be legitimate views. BRADY HARAN: All right, then. They're verifying the numbers. They're checking everything. I guess we probably could have guessed that. But why 301? TED HAMILTON: I was not there when the decision was made, but at some point the decision was made that we need to draw a line between what is innocuous and the database can handle, and what is all of a sudden serious business. The proportion was calculated to be at about 300, that this is the portion that we need to take care of. But the formula that we use to arrive at 300, I don't know if anyone actually knows that. BRADY HARAN: Well, OK. They drew a line in the sand. It was kind of arbitrary. They wanted to differentiate between people just sharing their home movies and the videos that are more popular,

4:39 the ones that are a bit more serious. The ones that need scrutiny. But that was 300. The view counter freezes at 301. What's going on here? Is there a reason? TED HAMILTON: Yeah, there is a reason. And the reason was the number 300 was chosen. And when someone's writing code, they need to put the logic in the code that says where you should stop, or where you should, if one condition is true, you go to the left. And the other condition is true, you go to the right. Now, this condition can be written like this. If the view count is less than 300, then go ahead and add one to the view count. Otherwise, go to x where x is our much more complicated view

5:30 count pipeline. However, what actually got written was not this, but if view count is less than or equal to 300, then increment the view count. So what this means is if the view count is at 300, this says is the view count less than or equal to 300? Yes, it is. Let me add one. So then you end up at 301. BRADY HARAN: Let me recap what's going on here. The code which is controlling where this view counter freezes contains a less than or equal to sign. So that means when a new early view comes along, it's checked against the code. Say the overall view count on the database is 299. OK, then. We'll let another one on. Here comes another view. Now the view count is 300.

6:16 That isn't less than 300, but it is equal to 300. So the code lets another view jump onto the total. Now we're at 301, and when another view comes along, it's not less than 300, but it's also not equal to 300 anymore, and the door is shut. There are going to be no more views added to the publicly visible count until YouTube have done their checks. And that will take half a day to a day. Then of course, all the extra views that have been counted in the interim all pile onto the total. Nothing's missed. At least that's what I'm told. TED HAMILTON: Yeah, so whoever wrote this code probably did not realize the magnitude of what they were doing. View counts have been around since the beginning of YouTube, and who was to know what YouTube would become.

7:03 So yeah, that was actually a rather monumental second of time in San Bruno, California, when a coder decided to write that logic in. It is now one of the idiosyncrasies of YouTube. BRADY HARAN: Now, I can hear some of you screaming at your computer screens. The view count doesn't stop at 301. Sometimes it stops at 302, or 305, or 310. What's going on there? There's an explanation for that, too, and that comes back to how I was saying the videos are shared around servers all across the world. So here's what's going on there. Views are coming in from the logs at the different videos, the different places around the world. And they're coming to this central database.

7:48 And we know the door's going to be shut at 301, we just explained that a minute ago. But what happens if views are coming in at the same time? Someone watched it in Africa at the exact same time someone watched in Europe. Now we've got multiple views coming in. Checking if they're allowed to join the count, yes they are. It's less than or equal to 300. So they all pile on at the same time. Now when a new view comes along, sorry, we're closed for business. But because of that simultaneous update, a few extra views were able to sneak on. TED HAMILTON: We get asked about it all the time. I wouldn't say that it causes angst, but it's certainly, I would classify it more as an annoyance.

8:33 You can go and see a very popular video, and you look and you'll see that it has 2,000 likes and 300 views. That's a little bit interesting. The issue there is that we don't put the likes through the same rigor, same rigorous process. And likes are far fewer in magnitude, so our systems can handle them more easily. But the views do freeze, and it can result in some awkward situations. But that actually results in terrific videos like this, so. BRADY HARAN: I did speak to Ted for maybe 45, 50 minutes and recorded it all. I've got loads of footage, a lot more detail, including a bit more about what constitutes a view. And I know some of you will want to see it. I haven't had time to edit it all just yet, but stay tuned because I'll be uploading that to

9:19 Numberphile in the near future. And for those of you who don't like these ones that are a bit more about computers and the internet, I'm sorry. Numberphile's always unpredictable, and I promise next time it might be something you enjoy a bit more. MATT PARKER: How many arrows do you want? So the next one, let's say we did 3 to the power of, to the power of, oh, arrow, arrow, arrow, or whatever you want to call this. 3. Will that--

Share

More video summaries