High-performance YouTube video streaming with mpv
Project description
mpv-yt
A command-line tool to stream YouTube videos with mpv.
Prerequisites
Requires mpv media player to be installed and available in your system's PATH.
Installation
pip install .
Usage
The tool can be invoked with the play command, followed by a YouTube video URL or ID. If no identifier is provided, the tool will prompt for input.
Interactive Mode
Run the command without a video identifier to be prompted for one. Then, select the desired stream quality from the interactive list.
play
Direct Playback
Provide a YouTube URL or video ID directly as an argument.
play "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
# or
play dQw4w9WgXcQ
Quality Selection
Specify a video quality to bypass the interactive selection. The tool supports specific resolutions (e.g., 1080p, 720p), highest, or lowest.
play dQw4w9WgXcQ --quality 1080p
Audio-Only Mode
Use the --audio flag to stream only the audio track.
play dQw4w9WgXcQ --audio
Options
| Argument | Short | Description |
|---|---|---|
identifier |
The YouTube URL or Video ID to play. | |
--quality <quality> |
-q |
Set a preferred quality (e.g., 1080p, highest, lowest). |
--audio |
-a |
Play audio only. |
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mpv_yt-1.0.0.tar.gz.
File metadata
- Download URL: mpv_yt-1.0.0.tar.gz
- Upload date:
- Size: 6.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6d4ff9e8adcac30841896900ceb077aaa2a0579049be855464f82e22f6b8f9ea
|
|
| MD5 |
57e424e0931093f2968f4cc82f809fe5
|
|
| BLAKE2b-256 |
6532e2e8b9348137773dd889622530867e9a1d70c754edd19929e0efda765f12
|
File details
Details for the file mpv_yt-1.0.0-py3-none-any.whl.
File metadata
- Download URL: mpv_yt-1.0.0-py3-none-any.whl
- Upload date:
- Size: 6.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0a75d3dd86da5515d769bb81d00504e943bcee78eddedfdd4832b23ee608f108
|
|
| MD5 |
2f8aeef091f5a03fa32d58020dda5015
|
|
| BLAKE2b-256 |
9a94f335fa51c29470402c0f05ecd98b36100f3664833e9ac1b3ddaa5041cf6d
|