Kunal Khude · Dev & Creator
Kunal Khude
Back to all projects
Android / MultimediaStatus: CompletedRole: Android Developer & Researcher

Background YouTube Player

An Android application experimenting with Android Intents and media services to receive shared YouTube video links via the OS share sheet and enable seamless background audio playback.

Background YouTube Player

Technology Used

AndroidKotlin / JavaAndroid Intents & Share SheetAndroid Foreground ServicesExoPlayer / Media3

1. Project Overview

Background YouTube Player is an experimental Android application that explores Android system integration, Intents, and background audio services. When users browse YouTube and tap the standard Android Share button, selecting this application immediately extracts the video reference and transitions audio to a background playback service.

Why I Built It

Built as an experimental dive into Android multimedia pipelines, Intent interception, background service lifecycles, and Android system-level share integration.

Problem I Wanted to Solve

On standard mobile devices, leaving the video app or locking the screen interrupts audio playback unless users have premium subscriptions, limiting multitasking while listening to lectures, podcasts, or music.

What I Built

A lightweight utility registering as an Android share target for video URLs, routing media streams through a foreground audio service that keeps playing when the screen is turned off or apps are switched.

Key Features

Native Android Share sheet integration receiving video links via SEND Intents
Seamless background audio playback resilient to screen lock and app switches
Foreground service implementation with persistent notification playback controls
Audio stream lifecycle management respecting OS media focus changes
Completely standalone experimental architecture without official API dependencies

Screenshots & Previews

Background YouTube Player preview 1

Technical Architecture

Receives URL parameters through an Intent filter, parses video stream descriptors, and binds them to an Android Foreground Service equipped with MediaSessionCompat and notification controls.

Technical Challenges & Solutions

The Technical Challenge

Handling Android battery optimization and background execution limits (Doze mode) that kill background tasks when the display turns off.

How I Solved It

Employed a compliant foreground service paired with a persistent media notification to maintain active audio playback without system interruption.

Key Insights & Takeaways

Mastered Android Intent filtering, deep system share hooks, multimedia service lifecycles, and audio focus arbitration.

Other Projects You Might Explore

View All Projects →