Commons:YouTube files

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search
Shortcut
COM:YT

YouTube is a video hosting platform, considered the largest one in the world (see its Wikipedia article).

Licensing[edit]

Most YouTube videos are not eligible for upload to Wikimedia Commons.

However, since June 2011, YouTube offers the option to license videos under the free license Creative Commons Attribution 3.0 (CC-BY) which is compatible with Commons. Under Commons policies, these videos may be transferred to Wikimedia Commons, with the usual caution that you should not upload work that appears to be plagiarized or is out of scope. Be also aware of YouTube's terms of service.

Some other videos don't use this license option, but include it:

  • in the video description (e.g. Wikipedia: Username, eligible for Commons and already here), or,
  • directly in the video (e.g. Blu - Muto, not eligible for Commons as CC BY-NC-ND).

Uploaded videos should be tagged with {{LicenseReview}} to request a license review to permanently document that the video really was available under that license. If they are released under CC-BY 3.0, you can add the license template {{Youtube}}.

Search videos licensed as Creative Commons on YouTube by visiting this YouTube link and replacing "SearchText" with a different search term.

Upload using video2commons[edit]

This easy tool to directly upload videos from source is helpful: video2commons. Please check free license before uploading.

WebM[edit]

In May 2010, Google introduced the free WebM video encoding format, and many videos from YouTube are available under this format. As of November 2012, Wikimedia Commons accepts WebM uploads. If videos are available in .webm format on YouTube, they may not need to be converted to a different format before uploading them to Commons. However, often the VP9 video streams from youtube do not have audio, and need to be recombined with an audio stream before being uploaded to Commons.

Command line

Moving to Commons with youtube2mediawiki [edit]

If the YouTube video is available in the WebM format and you are comfortable with running Python scripts on your machine, one possibility is to use youtube2mediawiki:

  1. Download and install python 2.7
  2. Download youtube2mediawiki (e.g. as ZIP-file)
  3. Extract the archive and use the command line to start the python script.

Downloading videos from YouTube[edit]

YouTube's own download option[edit]

If you are downloading a video from your own YouTube account, you can try following the instructions here: "Download your own YouTube videos"

Website / Webapp[edit]

  • SaveDeo.online Video Downloader is a free web application that allows you to download videos from YouTube. You only need the URL of the youtube page that has the freely licensed video you want to download. SaveDeo will then fetch download links in all possible formats, including WebM.
  • Y2Mate.com Video Downloader is a free web application that allows you to download videos from YouTube. You only need the URL of the youtube page that has the freely licensed video you want to download. KeepVid will then fetch download links in MP4 format.

Software[edit]

JDownloader allows downloading all videos from a specific account (useful for large numbers of videos) and specific formats, but is partly proprietary.

youtube-dl is also available as package in many GNU/Linux distributions, as well as Mac OS X.. However, youtube-dl does not offer a graphical user interface. Command line example:

youtube-dl --title --continue --retries 4 --write-info-json --write-description --all-subs --ignore-errors -f bestvideo+bestaudio --recode-video webm URL

If the video has a webm encoded version published (as according to youtube-dl -F URL, you can use the following to download the highest quality webm version:

youtube-dl -f bestvideo[ext=webm]+bestaudio[ext=webm]/best[ext=webm] URL

If the YouTube video has subtitles, youtube2srt can be used to download them in SRT format.

Firefox[edit]

Apart from various extensions a simple JavaScript bookmarklet will do the job in Firefox. Instructions can be found at github. You can then click on the bookmark anytime while watching a YouTube video. A list of download options will pop up in the top of the page.

Chrome[edit]

Chrome extensions claiming to support YouTube downloads are banned from the Webstore, and permitted download extensions in the Webstore (i.e., not working for YouTube) can be still malware.

Nerds comfortable with running Chrome in "developer mode" with locally installed extensions could try the Chrome-Youtube-Downloader.

Various sites offer to determine download URLs for a given YouTube page (and similar providers), e.g., KeepVid.com, SFrom.net, SaveDeo.online, etc. Obviously these sites can track what you are trying to get, but should be less risky than "unknown code from unknown 3rd party" extensions.

Simple example bookmarklets
javascript:void(window.open('http://savedeo.online/download?url='+location))
javascript:location.href='http://www.genyoutube.com/'+location.href.substring(24)

A recipe for the old (2011) Microsoft Download Manager for Windows: The determined download URLs typically contain some kind of session identification expiring after some time. If that hits you over very slow connections in the middle of a long download get a new URL, start it, stop it immediately, delete the almost empty remains, rename the incomplete old download to the new name, cancel the old download if still listed, and resume the new download. It should then continue where the first attempt was interrupted.

VLC media player[edit]

The following directions should work at least for a WebM version: Navigate to the desired video clip in your webbrowser. Copy the URL and open VLC media player and “Open Location from clipboard” (available from menu “Media” or via keyboard shortcut [Ctrl]+[V]). While the clip is playing or paused, open “Codec Infomation” (available from “Tools” menu or via keyboard shortcut [Ctrl]+[J]). Mark the URL string shown after “Location” (e.g. via triple click) and copy it to the clipboard (via context menu entry or keyboard shortcut [Ctrl]+[C]). Then open the dialogue window “Open Network stream...” and insert the copied URL. Click the dropdown menu available through the button next to the “Play” button select “Convert”. In the appearing new window select “Dump raw input”, type in a name for the “Destination file” and press the “Start” button. Now a file should be written to disk.

Conversion[edit]

Files not available in WebM have to be converted into WebM or Ogg Theora. See: Help:Converting video. If a file from youtube uses VP9 video, but vorbis audio, it can be converted using ffmpeg (or avconv) using a command like:

avconv -i inputfile.webm -acodec copy -vcodec libvpx out.webm

If you can get the (typically best) MP4 dash video, you might also want the M4A audio, to mux and transcode both into OGV or WebM, example:

ffmpeg -i input.mp4 -i input.m4a -f ogg -c:v libtheora -q:v 9 -c:a libvorbis -q:a 6 output.ogv

See also[edit]

Ways to get help
Crystal Clear app help index.svg