Skip to main content

altCensored fork of tubeup, a VOD service to Archive.org uploader

Unit Tests Lint

tubeupac uses yt-dlp to download a Youtube video (or any other provider supported by yt-dlp), and then uploads it with all metadata to the Internet Archive using the python module internetarchive.

tubeup was designed by the Bibliotheca Anonoma to archive single videos, playlists (see warning below about more than video uploads) or accounts to the Internet Archive.

This project is a fork of tubeup providing 8 additional options, enables the yt-dlp authentication option netrc (useful for oath2), and adds a simple retry for function 'internetarchive.get_item' that was failing with 'MaxRetryError':

--skip-download                               Don't download video but download image and json files.
--recode-video <rformat>                      Re-encode/re-mux the video into another format/container as needed.
                                              Same syntax and formats as --remux-video (ex: "mp4").
--new-item-id <item_id>                       new id for archive.org item (ex: "youtube-12345678912")
--ydl-option-format <format>                  yt-dlp option format (ex: "bestvideo[height<=1280]+bestaudio")
--ydl-option-subtitleslangs <subtitleslangs>  yt-dlp option subtitleslangs (ex: "all,-live_chat")
--ia-user <ia_user>                           system user for ia config file loading
--ia-s3-access <ia_s3_access>                 s3 access key
--ia-s3-secret <ia_s3_secret>                 s3 secret key

Prerequisites

This script strongly recommends Linux or some sort of POSIX system (such as macOS), preferably from a rented VPS and not your personal machine or phone.

Reccomended system specifications:

  • Linux VPS with Python 3.11 or higher and pip installed
  • 2GB of RAM, 100GB of storage or much more for anything other than single short video mirroring. If your OS drive is too small, symlink it to something larger.

Setup and Installation

  1. Install ffmpeg, pip3 (typically python3-pip), and git. To install ffmpeg in Ubuntu, enable the Universe repository.

For Debian/Ubuntu:

sudo apt install ffmpeg python3-pip git
  1. Use pip3 to install the required python3 packages. Python 3.11 or newer is required.
pip install tubeupac
  1. If you don't already have an Internet Archive account, register for one to give the script upload privileges.

  2. Configure internetarchive with your Internet Archive account.

ia configure

You will be prompted for your login credentials for the Internet Archive account you use.

Once configured to upload, you're ready to go.

  1. Start archiving a video by running the script on a URL (or multiple URLs) supported by yt-dlp.. For YouTube, this includes account URLs and playlist URLs.
tubeupac <url>
  1. Each archived video gets its own Archive.org item. Check out what you've uploaded at

    http://archive.org/details/@yourusername.

Perodically before running, upgrade tubeup and its dependencies by running:

pip install tubeupac -U

Docker

Dockerized tubeup is provided by etnguyen03/docker-tubeup. Instructions are provided.

Windows Setup

  1. Install WSL2, pick a distribution of your choice. Ubuntu is popular and well-supported.
  2. Use Windows Terminal by Microsoft to interact with the WSL2 instance.
  3. Fully update the Linux installation with your package manager of choice. sudo apt update ; sudo apt upgrade
  4. Install python pip and ffmpeg.
  5. Install Tubeup using steps 4-6 in the Linux configuration guide above and configuring internetarchive for your Archive.org account.
  6. Periodically update your Linux packages and pip packages.

Usage

Usage:
  tubeupac <url>... [--username <user>] [--password <pass>]
                     [--metadata=<key:value>...]
                     [--cookies=<filename>]
                     [--proxy <prox>]
                     [--quiet] [--debug]
                     [--use-download-archive]
                     [--output <output>]
                     [--ignore-existing-item]
                     [--new-item-id <item_id>]
                     [--ydl-option-format <format>]
                     [--ydl-option-subtitleslangs <subtitleslangs>]
  tubeupac -h | --help
  tubeupac --version
Arguments:
  <url>                         yt-dlp compatible URL to download.
                                Check yt-dlp documentation for a list
                                of compatible websites.
  --metadata=<key:value>        Custom metadata to add to the archive.org
                                item.
Options:
  -h --help                    Show this screen.
  -p --proxy <prox>            Use a proxy while uploading.
  -u --username <user>         Provide a username, for sites like Nico Nico Douga.
  -p --password <pass>         Provide a password, for sites like Nico Nico Douga.
  -a --use-download-archive    Record the video url to the download archive.
                               This will download only videos not listed in
                               the archive file. Record the IDs of all
                               downloaded videos in it.
  -q --quiet                   Just print errors.
  -d --debug                   Print all logs to stdout.
  -o --output <output>         yt-dlp output template.
  -i --ignore-existing-item    Don't check if an item already exists on archive.org

Metadata

You can specify custom metadata with the --metadata flag. For example, this script will upload your video to the Community Video collection by default. You can specify a different collection with the --metadata flag:

   tubeupac --metadata=collection:opensource_audio <url>

Any arbitrary metadata can be added to the item, with a few exceptions. You can learn more about archive.org metadata here.

Collections

Archive.org users can upload to four open collections:

Note that care should be taken when uploading entire channels. Read the appropriate section in this guide for creating collections, and contact the collections staff if you're uploading a channel or multiple channels on one subject (gaming or horticulture for example). Internet Archive collections staff will either create a collection for you or merge any uploaded items based on the YouTube uploader name that are already up into a new collection.

Dumping entire channels into Community Video is abusive and may get your account locked. Talk to the Internet Archive admins first before doing large uploads; it's better to ask for guidence or help first than run afoul of the rules.

If you do not own a collection you will need to be added as an admin for that collection if you want to upload to it. Talk to the collection owner or staff if you need assistance with this.

Troubleshooting

  • Some videos are copyright blocked in certain countries. Use the proxy or torrenting/privacy VPN option to use a proxy to bypass this. Sweden and Germany are good countries to bypass geo-restrictions.
  • Upload taking forever? Getting s3 throttling on upload? Tubeup has specifically been tailored to wait the longest possible time before failing, and we've never seen a S3 outage that outlasted the insane wait times set in Tubeup.

A note on live videos

Do not use Tubeup to archive live Youtube (or any other site) video. We will not/cannot fix it, it's not even our problem, and any solutions are unpalitable since they involve more code complexity to be maintained ontop of having to disable livechat for one extractor only for live video.

Major Credits (in no particular order)

  • emijrp who wrote the original youtube2internetarchive.py in 2012
  • Matt Hazinski who forked emijrp's work in 2015 with numerous improvements of his own.
  • Antonizoon for switching the script to library calls rather than functioning as an external script, and many small improvements.
  • Small PRs from various people, both in and out of BibAnon.
  • vxbinaca for stabilizing downloads/uploads in yt-dlp/internetarchive library calls, cleansing item output, subtitles collection, and numerous small improvements over time.
  • mrpapersonic for adding logic to check if an item already exists in the Internet Archive and if so skips ingestion.
  • Jake Johnson of the Internet Archive for adding variable collections ability as a flag, switching Tubeup from a script to PyPi repository, ISO-compliant item dates, fixing what others couldn't, and many improvements.
  • Refeed for re-basing the code to OOP, turning Tubeup itself into a library. and adding download and upload bar graphs, and squashing bugs.

License (GPLv3)

Copyright (C) 2020 Bibliotheca Anonoma

Copyright (C) 2024 altCensored.com

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

Metadata

Release files for tubeupac 2026.10.29.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for tubeupac 2026.10.29.1
File Size Uploaded Provenance Actions
tubeupac-2026.10.29.1.tar.gz 42.2 kB Without provenance Details for tubeupac-2026.10.29.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for tubeupac 2026.10.29.1
File Interpreter ABI Platform Actions
tubeupac-2026.10.29.1-py3-none-any.whl Python 3 none any Details for tubeupac-2026.10.29.1-py3-none-any.whl

Total release size: 72.5 kB

Release files / tubeupac-2026.10.29.1.tar.gz

Download URL tubeupac-2026.10.29.1.tar.gz
Size 42.2 kB
Tags Source
SHA-256 checksum
How to use checksums
48e9f90fa02f12924b8e24d2ae5eceb976427f4c034814a30194e2cd1e7dd8e0
BLAKE2b-256 checksum
How to use checksums
139b7cde14af43de6da5b4ea8da528fddd4129ae4844fff8866a9d3ed722d5f7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.5

Release files / tubeupac-2026.10.29.1-py3-none-any.whl

Download URL tubeupac-2026.10.29.1-py3-none-any.whl
Size 30.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
27c22a844d00c034dec24b937c538a045558bf5216935c5faaa8da111a0b47d0
BLAKE2b-256 checksum
How to use checksums
eeeca8bf5dd96c4661cd4832e4efb8d3f7a3e0afa7a31e6d23162fada1bb5121
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.5

Security for tubeupac 2026.10.29.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

2026.10.29.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page