Commons:YouTube files

Shortcut
COM:YT

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

LicensingEdit

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.

WebMEdit

Shortcut
COM:WEBM

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. There are two different types of WebM formats - VP8 and the newer VP9 (available since June 2013). Some of youtube's higher resolution videos tend to be in VP9 formatted webm, and won't work on commons unless converted to the older VP8 type of webm. (c.f. bugzilla:53863)

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 YouTubeEdit

YouTube's own download optionEdit

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

SoftwareEdit

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. 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 bestaudio+bestvideo --recode-video webm URL

FirefoxEdit

Apart from various extensions such as BYTubeD 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.

ChromeEdit

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.com, 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 bookmarklet
javascript:void(window.open('http://savedeo.com/download?url='+location))

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 playerEdit

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.

ConversionEdit

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 alsoEdit


Ways to get help
Crystal Clear app help index.png
https://commons.m.wikimedia.org/wiki/Commons:YouTube_files
commons.m.wikimedia.org
crawl=CC-MAIN-2015-40
26307
application/http; msgtype=response
sha1:QIVPFICKVGWXC4X4VTP42HHFOM2M4LBU
<urn:uuid:a7af9ec7-dcd8-465e-90d0-0ebdb876eb5d>
2015-10-13T18:50:49Z
208.80.154.236
sha1:AANHEPXR5PSRR2KE6IKD7B5S62YD5JHG
<urn:uuid:fb192bf7-6c74-45a3-9219-25b1d3854c6d>
https://commons.m.wikimedia.org/wiki/Commons:YouTube_files
response
<urn:uuid:30c9704b-d968-44d4-b65f-c4af259e054d>
robots: classic
hostname: ip-10-137-6-227.ec2.internal
software: Nutch 1.6 (CC)/CC WarcExport 1.0
isPartOf: CC-MAIN-2015-40
operator: CommonCrawl Admin
description: Wide crawl of the web for September 2015
publisher: CommonCrawl
format: WARC File Format 1.0
conformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf