Welcome to Popcorn! This guide will help you get started with your cable-style movie scheduling system for Plex.
- Overview
- Prerequisites
- Getting Your Plex Credentials
- Installation Methods
- Configuration
- Using Popcorn
- Troubleshooting
Popcorn creates cable TV-style movie channels from your Plex media library. It automatically generates:
- Genre-based channels (Action, Comedy, Drama, etc.) based on your movies
- Seasonal holiday channels (Cozy Halloween, Scary Halloween, Christmas)
- 24-hour schedules with movies playing back-to-back
- TV guide interface for browsing what's "on air"
Before installing Popcorn, you'll need:
- A Plex Media Server running with a movie library
- Docker (for Docker installation) - Install Docker
- OR Python 3.11+ (for direct installation)
- Network access to your Plex server
- Plex authentication token (instructions below)
Your Plex URL is typically:
- Local network:
http://192.168.1.100:32400(replace with your server's IP) - Remote access:
https://YOUR-SERVER-ID.plex.direct:32400
To find your server IP:
- Open Plex Web App
- Go to Settings → Network
- Note the IP address shown
- Open a movie in Plex Web App
- Click the three dots (⋮) → "Get Info"
- Click "View XML"
- Look in the URL bar for
X-Plex-Token=XXXXX - Copy everything after the equals sign
- Open Plex Web App in your browser
- Press
F12to open Developer Tools - Go to the Console tab
- Type:
localStorage.getItem('myPlexAccessToken') - Press Enter and copy the token (without quotes)
- Sign in at https://www.plex.tv/sign-in
- Navigate to: https://plex.tv/devices.xml
- Find your server in the XML and look for
token="YOUR_TOKEN"
To play movies directly on a Plex client (like Roku):
- Make sure your Plex client is running and connected to your server
- The client name is usually the device name (e.g., "Roku Living Room")
- You can see available clients in Popcorn at: Settings → View Available Clients
If you're running Unraid, see the dedicated UNRAID_SETUP.md guide for:
- Installing from Community Applications
- Manual template installation
- Unraid-specific configuration
- Troubleshooting on Unraid
Docker is the easiest way to run Popcorn. It handles all dependencies automatically.
# Navigate to the Popcorn directory
cd /path/to/popcorn
# Build the Docker image
docker build -t popcorn .This will take a few minutes to download dependencies and build the image.
Basic setup (without Plex):
docker run -d \
--name popcorn \
-p 5000:5000 \
-e SESSION_SECRET="your-random-secret-key-change-this" \
popcornFull setup (with Plex connection):
docker run -d \
--name popcorn \
-p 5000:5000 \
-e SESSION_SECRET="your-random-secret-key-change-this" \
-e PLEX_URL="http://192.168.1.100:32400" \
-e PLEX_TOKEN="your-plex-token-here" \
-e PLEX_CLIENT="Roku Living Room" \
-v popcorn-data:/app \
--restart unless-stopped \
popcornEnvironment Variables Explained:
SESSION_SECRET- Random string for session security (required)PLEX_URL- Your Plex server URL (required for Plex features)PLEX_TOKEN- Your Plex authentication token (required for Plex features)PLEX_CLIENT- Name of your Plex playback device (optional, for direct playback)
Open your browser and go to:
http://localhost:5000
Or from another device on your network:
http://YOUR-SERVER-IP:5000
# Stop Popcorn
docker stop popcorn
# Start Popcorn
docker start popcorn
# View logs
docker logs popcorn
# Remove container
docker rm -f popcornWhen running in Docker, Popcorn will automatically detect updates but won't apply them automatically (Docker best practice). To update:
Step 1: Check for Updates
- Go to Settings (admin only)
- Click "Check for Updates"
- If an update is available, you'll see: "Running in Docker: Please pull the latest image to update"
Step 2: Pull and Restart
# Pull the latest image
docker pull netpersona/popcorn:latest
# Stop and remove the old container
docker stop popcorn
docker rm popcorn
# Start with the new image (use your original docker run command)
docker run -d \
--name popcorn \
-p 5000:5000 \
-e SESSION_SECRET="your-secret-here" \
-e PLEX_URL="http://192.168.1.100:32400" \
-e PLEX_TOKEN="your-token" \
-v popcorn-data:/app \
--restart unless-stopped \
netpersona/popcorn:latestNote: Your database and settings are preserved in the volume, so you won't lose any data.
If you prefer not to use Docker:
# Make sure you have Python 3.11+ installed
python --version
# Install dependencies
pip install -r requirements.txtLinux/Mac:
export SESSION_SECRET="your-random-secret-key"
export PLEX_URL="http://192.168.1.100:32400"
export PLEX_TOKEN="your-plex-token"
export PLEX_CLIENT="Roku Living Room"Windows (PowerShell):
$env:SESSION_SECRET="your-random-secret-key"
$env:PLEX_URL="http://192.168.1.100:32400"
$env:PLEX_TOKEN="your-plex-token"
$env:PLEX_CLIENT="Roku Living Room"Or create a .env file:
SESSION_SECRET=your-random-secret-key
PLEX_URL=http://192.168.1.100:32400
PLEX_TOKEN=your-plex-token
PLEX_CLIENT=Roku Living Room
python app.pyAccess at http://localhost:5000
For quick evaluation and demo purposes, Popcorn automatically creates two default accounts on first startup:
| Username | Password | Role | Purpose |
|---|---|---|---|
admin |
admin |
Administrator | Full access to all features and settings |
demo |
demo |
User | Standard user access for demonstration |
- Access Popcorn in your browser (e.g.,
http://localhost:5000) - Log in with either:
- Admin account:
admin/admin - Demo account:
demo/demo
- Admin account:
- Security Warning Appears: You'll see a red pulsing banner at the top:
⚠️ SECURITY WARNING: You are using a default password! Change your password immediately in your profile settings. - Change Password Immediately:
- Click the warning banner or navigate to Profile
- Scroll to "Change Password" section
- Enter current password, new password, and confirm
- Click "Change Password"
- Security warning disappears automatically
- Start Popcorn with your Plex credentials configured (see environment variables)
- Automatic sync will begin - Popcorn scans your Plex library
- Channels are generated automatically based on movie genres
- Schedules are created with 24-hour programming
Access settings at: http://localhost:5000/settings
Reshuffle Frequency:
- Daily - New schedule every day at midnight
- Weekly - New schedule every 7 days
- Monthly - New schedule every 30 days
Manual Actions:
- Reshuffle Now - Generate new schedules immediately
- View Available Clients - See connected Plex devices
Holiday channels are automatically activated during their seasons:
| Channel | Active Period | Content | Rating Filter |
|---|---|---|---|
| Cozy Halloween 👻 | September - November | Family-friendly Halloween movies | G, PG, PG-13 |
| Scary Halloween 💀 | September - November | Horror and scary movies | PG-13, R |
| Christmas 🎄 | November - January | Christmas and holiday movies | All ratings |
The main interface shows a grid-style TV guide:
- Channel list on the left shows all available channels
- Time grid across the top (24 hours in 30-minute increments)
- Program tiles show what's playing at each time
- Current time indicator (orange line) shows "now"
- Jump to Now button scrolls to current time
Interacting with the Guide:
- Scroll horizontally to see different times
- Scroll vertically to browse channels
- Click any program tile to open it in Plex
Browse channels individually:
- See all channels in a card layout
- Shows what's currently playing on each channel
- Click a channel to see its full 24-hour schedule
On Desktop/Mobile:
- Click any movie in the guide or schedule
- A new tab opens attempting to launch Plex
- If Plex app is installed, it opens the movie
- Otherwise, you're redirected to Plex Web to cast/play
On TV/Roku:
- Browse Popcorn on your phone/tablet/computer
- Click a movie to open it in Plex
- From Plex app/web, cast to your Roku or TV
- Movie plays on your TV through Plex
To update Popcorn with new movies:
- Go to the menu and click Sync
- Or manually visit:
http://localhost:5000/sync - Popcorn scans your Plex library for new movies
- New movies are added to appropriate channels
- Schedules are regenerated automatically
Popcorn includes 11 built-in themes plus support for custom themes:
Built-in Themes:
- Plex - Classic Plex dark theme (default)
- Halloween - Orange and black with coral accents
- Hell-o-ween - Dark and fiery with orange/red accents
- Pastel Dream - Soft pastel colors
- Plastic - Modern gradient design
- Popcorn - Warm theater-inspired colors
- Midnight Harmony - Deep blues and purples
- Ichor Wine - Rich burgundy tones
- Vampirism - Dark purple vampire aesthetic
- Lavender - Soft purple theme
- Starry Night - Dark blue night sky theme
Changing Your Theme:
- Navigate to Profile page (via hamburger menu)
- Find the "Theme Selection" section
- Choose from the dropdown
- Click "Save Theme"
- Theme applies instantly across all pages
Creating Custom Themes:
You can upload your own custom theme JSON files:
- Go to Profile page
- Click "Upload Theme" button
- Select your JSON theme file (max 50KB)
- Theme appears with a ⭐ star icon
- Select and save to apply
Custom Theme Format:
Create a JSON file with the following structure:
{
"name": "My Custom Theme",
"description": "A unique theme I created",
"bg-primary": "#1a1a1a",
"bg-secondary": "#2d2d2d",
"bg-tertiary": "#3d3d3d",
"accent": "#ff6b6b",
"accent-hover": "#ff5252",
"text-primary": "#ffffff",
"text-secondary": "#cccccc",
"text-muted": "#888888",
"border": "#444444",
"shadow": "rgba(0, 0, 0, 0.3)"
}Requirements:
- All 10 color properties are required
- Must be valid JSON format
- File size under 50KB
- Use valid CSS color values (hex, rgb, rgba)
Managing Custom Themes:
- Your custom themes show with a ⭐ star icon
- Click the trash icon to delete themes you own
- Admins can mark custom themes as public for all users
Configure how movies play when you click them:
Playback Mode:
- Web Player (default) - Opens in browser
- Client Playback - Sends to configured Plex device (Roku, Apple TV, etc.)
Time Offset:
- Enabled (default) - Movies start at their current "live" position
- Disabled - Movies always start from the beginning
Access these settings from your Profile page.
Your profile page shows:
- Username and email - Account information
- Theme selection - Choose or upload themes
- Playback settings - Configure movie playback
- Avatar - Circular profile picture
- Password management - Change your password
To update your password:
- Navigate to Profile (via hamburger menu → Profile)
- Scroll to Account Information section
- Find "Change Password" section
- Fill in the form:
- Current Password: Your existing password
- New Password: Your new password (minimum 4 characters)
- Confirm New Password: Re-enter new password
- Click "Change Password"
- Success: Password updated, security warning removed (if applicable)
Password Requirements:
- Minimum 4 characters
- Must match confirmation field
- Current password must be correct
Common Errors:
- "Current password is incorrect" - Check your existing password
- "New passwords do not match" - Ensure both new password fields match
- "Password must be at least 4 characters" - Use a longer password
Security Tips:
- Use a unique password not used elsewhere
- Change default passwords immediately after first login
- Choose a memorable but secure password
- Avoid common words or patterns
Symptoms: App works but shows no movies, channels are empty
Solutions:
-
Verify
PLEX_URLis correct:curl http://YOUR-PLEX-URL:32400/identity
Should return XML with server info
-
Verify
PLEX_TOKENis correct:curl "http://YOUR-PLEX-URL:32400/library/sections?X-Plex-Token=YOUR-TOKEN"Should return your libraries
-
Check network connectivity:
- Make sure Popcorn can reach your Plex server
- If using Docker, ensure containers can communicate
- Check firewall rules
-
Restart with correct environment variables:
docker restart popcorn # Check logs docker logs popcorn
Symptoms: Error message about Plex client not available
Solutions:
- Make sure your Plex client (Roku, etc.) is powered on
- Verify the client is connected to the same Plex account
- Check available clients:
- Go to Settings → View Available Clients
- Find the exact name of your client
- Update
PLEX_CLIENTenvironment variable with correct name:docker rm -f popcorn docker run -d --name popcorn -p 5000:5000 \ -e PLEX_CLIENT="Correct Client Name" \ ... (other env vars) \ popcorn
Symptoms: Clicking movies doesn't open Plex
Solutions:
-
On mobile devices:
- Install the official Plex app
- Sign in with your Plex account
- Grant browser permission to open apps
-
On desktop:
- Install Plex Desktop app or Plex Media Player
- Sign in with your Plex account
- Use the web fallback link if app doesn't open
-
On Roku/TV:
- Use second-screen control (browse on phone, cast to TV)
- Open movie in Plex app/web
- Select your Roku/TV as the playback device
Symptoms: "No Channels Available" message
Solutions:
-
Check if Plex library has movies:
- Open Plex and verify movies exist
- Movies must have genre tags
-
Trigger a sync:
- Visit:
http://localhost:5000/sync - Wait for sync to complete (check logs)
- Visit:
-
Check application logs:
docker logs popcorn
Look for errors during movie sync
Symptoms: Movies don't appear in genre channels
Solutions:
- In Plex, edit the movie metadata
- Add appropriate genre tags
- Sync Popcorn:
http://localhost:5000/sync - Movies will appear in matching genre channels
Symptoms: "Address already in use" error
Solutions:
-
Use a different port:
docker run -p 8080:5000 ... popcorn
Access at
http://localhost:8080 -
Or stop the conflicting service:
# Find what's using port 5000 lsof -i :5000 # Stop that process
Symptoms: Docker container exits immediately
Solutions:
-
Check logs:
docker logs popcorn
-
Common issues:
- Missing required environment variables
- Invalid Plex credentials
- Port conflicts
-
Run interactively to debug:
docker run -it --rm -p 5000:5000 \ -e SESSION_SECRET="test" \ popcorn
Symptoms: Same movies showing repeatedly
Solutions:
- Check reshuffle frequency in Settings
- Manually trigger reshuffle:
- Go to Settings
- Click "Reshuffle Now"
- Or restart the application:
docker restart popcorn
Symptoms: Errors about database or SQLite
Solutions:
-
Stop the container:
docker stop popcorn
-
Delete the database (will resync from Plex):
docker exec popcorn rm -f popcorn.db -
Restart and let it rebuild:
docker start popcorn
If you're still experiencing issues:
-
Check application logs:
docker logs -f popcorn
-
Verify configuration:
docker exec popcorn env | grep PLEX
-
Test Plex connection manually:
curl "http://YOUR-PLEX-URL:32400/library/sections?X-Plex-Token=YOUR-TOKEN" -
Restart everything:
docker restart popcorn
- Keep Plex metadata accurate - Proper genres and ratings help channel organization
- Sync regularly - Run sync after adding new movies to your library
- Use reshuffle - Change schedules weekly for variety
- Bookmark the guide - Set as your homepage for quick access
- Use on multiple devices - Browse on phone, cast to TV
Create docker-compose.yml:
version: '3.8'
services:
popcorn:
build: .
container_name: popcorn
ports:
- "5000:5000"
environment:
- SESSION_SECRET=your-secret-key-here
- PLEX_URL=http://192.168.1.100:32400
- PLEX_TOKEN=your-plex-token
- PLEX_CLIENT=Roku Living Room
volumes:
- popcorn-data:/app
restart: unless-stopped
volumes:
popcorn-data:Run with:
docker-compose up -dlocation /popcorn/ {
proxy_pass http://localhost:5000/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}This section covers features available only to administrator accounts.
Admins can manage user accounts and create invitation codes.
Accessing User Management:
- Open the hamburger menu
- Click "Settings" (admin only)
- Navigate to "User Management" section
Creating Invitation Codes:
- Go to Settings → User Management
- Click "Create Invitation Code"
- Optionally set an email and expiration date
- Share the code with new users
- Users register at
/register?code=YOUR_CODE
Managing Users:
- View all registered users
- Toggle admin privileges
- Activate/deactivate accounts
- View registration and login history
User Roles:
- Admin - Full access to settings, user management, and updates
- User - Access to guide, channels, profile, and theme customization
For Native Installations (Non-Docker):
Popcorn includes an intelligent auto-update system that checks GitHub for new releases:
Checking for Updates:
- Go to Settings
- Scroll to "Updates" section
- Click "Check for Updates"
- System shows current version and available updates
Applying Updates:
- When update is available, click "Update Now"
- Watch real-time progress:
- Database backup created automatically
- Latest code downloaded from GitHub
- Dependencies updated
- Database migrations applied
- On success: Restart the application
- On failure: Automatic rollback to backup
Update Features:
- Automatic database backup before updates
- Real-time progress streaming
- Migration tracking (no duplicate migrations)
- Automatic rollback on failure
- Version history tracking
For Docker Installations:
Docker containers are updated differently:
- Go to Settings → Updates
- Click "Check for Updates"
- If available, message shows: "Running in Docker: Please pull the latest image to update"
- Follow Docker update instructions (see Docker section above)
Update Source:
- Updates are checked from:
https://github.com/netpersona/Popcorn - Configurable in database settings
- Checks
/releases/latestfor new versions
Plex Connection:
- Configure Plex URL and token
- Test connection to verify credentials
- View available Plex clients for playback
Schedule Management:
- Set reshuffle frequency (daily, weekly, monthly)
- Manually trigger schedule regeneration
- View last reshuffle date
System Information:
- View current version and commit
- Check for updates
- Review deployment environment (Docker/Native)
Theme Permissions:
- All users can upload and use custom themes
- Admins can mark custom themes as "public"
- Public themes are available to all users
Making Themes Public:
- Navigate to Profile
- Find the custom theme
- (Admin only) Click "Make Public"
- Theme now appears for all users
Theme Management:
- Monitor uploaded custom themes
- Delete inappropriate themes
- Set default theme for new users
- Change default passwords immediately - Update
adminanddemoaccounts on first login - Keep SESSION_SECRET secure - Never share this value
- Protect ADMIN_SETUP_TOKEN - Used for first admin registration only
- Regularly update - Apply security patches when available
- Monitor user activity - Review login history
- Use strong passwords - Enforce for local auth users (minimum 4 characters)
- Limit admin access - Only trusted users should have admin privileges
- Review security warnings - Address any security banners immediately
Default Account Security:
- Default accounts (
admin/admin,demo/demo) are created automatically for quick setup - These accounts display security warnings until passwords are changed
- Production deployments: Change or disable default accounts before public access
- Demo deployments: Acceptable for temporary testing, but still change passwords
- Security warnings persist across sessions until passwords are updated
Database Backups:
- Auto-update system creates backups before updates
- Located in
/backupsdirectory - Timestamped format:
popcorn_YYYYMMDD_HHMMSS.db
Manual Backup:
# Docker
docker cp popcorn:/app/popcorn.db ./backup-$(date +%Y%m%d).db
# Direct Installation
cp popcorn.db backup-$(date +%Y%m%d).dbRestore from Backup:
# Docker
docker stop popcorn
docker cp ./backup.db popcorn:/app/popcorn.db
docker start popcorn
# Direct Installation
cp backup.db popcorn.db
python app.pyPopcorn automatically tracks and applies database migrations:
Migration System:
- Migrations stored in
/migrationsdirectory - Tracked in
migration_historytable - Only new migrations are applied
- Prevents duplicate execution
Viewing Migrations:
# Docker
docker exec popcorn ls -l /app/migrations
# Direct Installation
ls -l migrations/Migration History: All applied migrations are recorded with timestamps to prevent re-execution.
Problem: Can't Access Admin Features
Solutions:
- Verify your account has admin privileges
- Check User Management to see your role
- Contact the original admin to grant permissions
Problem: Update Failed
Solutions:
- Check application logs for errors
- Database backup is automatically restored
- Verify GitHub connectivity
- Check available disk space
- Try manual update via git pull
Problem: Users Can't Register
Solutions:
- Verify invitation code is valid and not expired
- Check code is active in User Management
- Ensure ADMIN_SETUP_TOKEN is secure (first admin only)
- Check application logs for registration errors
Enjoy your cable TV experience with Popcorn! 🍿📺