These are the top YouTube videos that went viral in 2017

The masked performer was a contestant on Thailand's aptly named singing competition show "The Mask Singer." The man in the mask sings "Until We Will Become Dust," which starts out as a ballad and eventually breaks into a rap.

The video has more than 182 million views on YouTube.

YouTube determined its top trending videos based on time spent watching, sharing, commenting, liking and other metrics. Here are the other top videos that went viral this year, in order.

-- Ed Sheeran's "Shape of You" had people dancing all summer, although most people probably didn't have moves like the ones in this choreography.

-- Seven minutes and 16 seconds of incredible table tennis trick shots. You probably don't want to play beer pong against these guys.

-- This 12-year-old singing ventriloquist's amazing performance on "America's Got Talent." It was so good it got her the Golden Buzzer treatment, sending her straight to the live shows.

-- Ed Sheeran made the list twice. This time, it was his debut on James Corden's "Carpool Karaoke," in which we learned Sheeran could stuff 55 Maltesers into his mouth at one time and that he doesn't own a cellphone.

The most watched music videos of 2017

Here are the most watched music videos of the year. No surprise here: "Despacito" took the crown. Not only is Luis Fonsi and Daddy Yankee's massive hit the most viewed music video this year, but it's also the most viewed YouTube video of all time. Also worth noting is that six of the top 10 are sung in Spanish.