Fetch YouTube Cover Images
GeekThis remains completely ad-free with zero trackers for your convenience and privacy. If you would like to support the site, please consider giving a small contribution at Buy Me a Coffee.
With the not so new YouTube Layout now, you may need to grab a banner on someones page for one reason or another. This took me a little bit of time to figure out and I didn’t see it posted anywhere else, so what better place to post it than here. So far, I have found 4 different sizes that seem to cover all of the available screen types. Desktop, Mobile, Tablet and TV. If you want to see the full cover image with the highest resolution, look at the TV images.
Getting The Cover Images
- Copy the URL https://www.youtube.com/feeds/videos.xml?user=geekthisnet into a new tab. Replace the username “geekthisnet” with the username you want to fetch the cover image of.
- Find the Channel ID from the RSS feed of the page you just visited.
The channel id will be located inside the tag
<yt:channelId>. For GeekThisNet, the channel ID is
jdbOdrjTVonDK9CwZKlhAg. You have to remove the first two characters of
UCfrom the beginning of the Channel ID to get the real channel ID.
Image Names: Mobile: channels4_mobile_banner.jpg Desktop: channels4_banner.jpg TV: channels4_tv_banner.jpg Tablet: channels4_tablet_banner.jpg Resolutions: Mobile: 640 x 176 Desktop: 1060 x 176 TV: 2120 x 1194 Tablet: 1707 x 283 Final URL: http://i.ytimg.com/u/CHANNEL_ID/THE_IMAGE_NAME GeekThis URL Example: Mobile: http://i.ytimg.com/u/jdbOdrjTVonDK9CwZKlhAg/channels4_mobile_banner.jpg Desktop: http://i.ytimg.com/u/jdbOdrjTVonDK9CwZKlhAg/channels4_banner.jpg TV: http://i.ytimg.com/u/jdbOdrjTVonDK9CwZKlhAg/channels4_tv_banner.jpg Tablet: http://i.ytimg.com/u/jdbOdrjTVonDK9CwZKlhAg/channels4_tablet_banner.jpg
The reason the tablet resolution is so high is for retina displays. The resolution has to be doubled the regual resolution because there are more pixels per inch. The Final URL has two strings to be replaced. The channel_id and the image name. The image name are those listed next to the devices.