Skip to content

derhuerst/play-on-apple-tv

Repository files navigation

play-on-apple-tv

A command line tool to play any audio/video on an Apple TV.

asciicast

npm version ISC-licensed minimum Node.js version support me via GitHub Sponsors chat with me via Matrix

Usage

Using npx:

npx play-on-apple-tv some-audio-file.mp3 my-apple-tv.local
npx play-on-apple-tv 'http://some-server/some-audio-file.mp3' my-apple-tv.local

Find the name of your Apple TV using bonjour-browser:

npx bonjour-browser | grep airplay

Play a Youtube video by finding the raw video url using yt-dlp:

npx play-on-apple-tv $(yt-dlp -f 40 --get-url 'https://www.youtube.com/watch?v=jNQXAC9IVRw') my-apple-tv.local

Contributing

If you have a question or have difficulties using play-on-apple-tv, please double-check your code and setup first. If you think you have found a bug or want to propose a feature, refer to the issues page.