YT-DLP WebUI Configuration — .env File, Settings, Rebranding & HTTPS

Jun 20, 2026 • 4 min read

Configure YT-DLP WebUI — the .env file, web UI download settings, rebranding, and HTTPS setup for your self-hosted server.

There are two ways to configure YT-DLP Web:

  1. .env file — server-level settings (port, HTTPS, admin credentials, rebranding)
  2. Web UI settings — download preferences (folders, concurrent downloads, rate limits)

📄 The .env File

The .env file sits in the project root directory and contains settings that are loaded when the server starts. Any changes require a server restart.

How to set it up

# Copy the example file
cp .env.example .env

# Edit with any text editor
nano .env

All .env Variables

🏷️ App Settings

VariableDefaultWhat it does
APP_NAMEYT-DLP WEBChanges the app name shown in the navigation bar, page titles, and footer
APP_LOGO_ICONicon-downloadThe SVG icon displayed next to the app name (pick from icons in base.html)
APP_FAVICONSVG data URI (download arrow)The icon that appears in browser tabs
APP_SECRET_KEYchange-me-in-production-use-random-string🔑 Important: Used to sign session cookies. Set a random string in production
Rebranding Example

Want to call it “My Downloader” instead?

APP_NAME="My Downloader"
APP_LOGO_ICON="icon-play"        # Must be an icon ID from base.html
APP_FAVICON="https://example.com/favicon.ico"

💡 Available icons: icon-download, icon-home, icon-play, icon-settings, icon-history, icon-monitor, icon-system, icon-trash, icon-cancel, icon-retry, etc.

🌐 Server Settings

VariableDefaultWhat it does
PORT8000Which port the web server listens on
USE_SSLfalseSet to true to enable HTTPS
SSL_CERT_FILEssl/cert.pemPath to your SSL certificate file
SSL_KEY_FILEssl/key.pemPath to your SSL key file
Enabling HTTPS
# 1. Edit .env
USE_SSL=true

# 2. Generate a self-signed certificate
mkdir -p ssl
openssl req -x509 -newkey rsa:4096 -keyout ssl/key.pem \
  -out ssl/cert.pem -days 365 -nodes -subj '/CN=localhost'

# 3. Restart the server
./run.sh

Now access your app at https://localhost:8000.

🔒 For production, use a certificate from Let’s Encrypt instead of a self-signed one.

👤 Auth Settings

VariableDefaultWhat it does
ADMIN_USERNAMEadminThe default admin account username
ADMIN_PASSWORDadmin123⚠️ Change this in production! The admin account password

On first startup, if no users exist in the database, the app automatically creates an admin account using these credentials.

🗄️ Database Settings

VariableDefaultWhat it does
DB_PATHapp/data/ytdlp.dbWhere the SQLite database file is stored

📝 Logging Settings

VariableDefaultWhat it does
LOG_PATHlogs/ytdlp-web.logWhere log files are written
LOG_LEVELINFOHow detailed logs are: DEBUG, INFO, WARNING, ERROR, CRITICAL
LOG_MAX_BYTES10485760Max size of a single log file (10MB) before rotation
LOG_BACKUP_COUNT5How many old log files to keep

🖥️ Web UI Settings

These are managed from Settings → Downloads in the app. They’re stored in the database — no file editing needed.

Download Settings

SettingDefaultWhat it does
output_dirdownloadsWhere downloaded files are saved
max_concurrent_downloads3How many downloads can run at the same time
rate_limit(empty)Speed limit (e.g., 1M = 1 MB/s, 500K = 500 KB/s)
subtitle_langenSubtitle language(s) to download (e.g., en,es,fr)
embed_thumbnailfalseEmbed the video thumbnail in the output file
embed_metadatafalseEmbed metadata (title, upload date, etc.) in the file
container_preference(empty)Preferred container format: mkv, mp4, or webm
auto_updatemanualyt-dlp auto-update: manual, daily, or weekly
download_archive(empty)Path to an archive file (tracks downloaded URLs to skip repeats)
show_thumbnailstrueShow video thumbnails in the job list on the dashboard

Proxy Settings

SettingWhat it does
http_proxyHTTP proxy URL (e.g., http://proxy:8080)
socks_proxySOCKS proxy URL (e.g., socks5://proxy:1080)

Organization Settings

SettingWhat it does
folder_templateTemplate for organizing downloads (default: downloads/{domain}/{date})
organize_by_domainGroup downloads by source domain (YouTube, Vimeo, etc.)
organize_by_dateGroup downloads by date

File Management

SettingDefaultWhat it does
cookie_file_path(empty)Path to a cookies.txt file for accessing private/age-restricted content

🔐 Complete HTTPS Guide

Option 1: Self-Signed Certificate (quick and easy)

# Set in .env
USE_SSL=true

# Generate certificate
mkdir -p ssl
openssl req -x509 -newkey rsa:4096 -keyout ssl/key.pem \
  -out ssl/cert.pem -days 365 -nodes -subj '/CN=localhost'

# Restart
./run.sh

Your browser will show a “Not Secure” warning — this is normal for self-signed certs. Click “Advanced” → “Proceed” to continue.

Option 2: Let’s Encrypt (production)

For a proper trusted certificate, use a reverse proxy (like Nginx or Caddy) with Let’s Encrypt in front of the app.


🌓 Theme

There’s no manual theme setting — the UI automatically follows your operating system’s dark/light mode. Switch your system theme and the app follows along.


📤 Exporting & Importing Settings

You can backup or migrate all settings (including custom presets) as a JSON file:

  • Export: Settings → Export → saves a .json file
  • Import: Settings → Import → upload a previously exported .json file

Great for:

  • Moving to a new server
  • Sharing your setup
  • Keeping a backup before major changes