Your Plex server is probably the most exposed service on your home network. It has an open port, handles authentication through a third-party cloud service, serves media to devices across the internet, and runs on hardware that likely hosts other services too. The August 2022 Plex data breach — which exposed emails, usernames, and encrypted passwords for over 20 million accounts — was a wake-up call that most users still haven’t acted on. Here’s how to lock it down properly.
Don’t Expose Plex Directly to the Internet
The default Plex setup asks you to forward port 32400 from your router to your Plex server. This works, but it means anyone who discovers your public IP and port can directly interact with the Plex web server. While Plex requires authentication, any vulnerability in the Plex web server (and there have been several) becomes directly exploitable from the internet.
Better options, in order of security:
- Reverse proxy with Cloudflare Tunnel or Tailscale Funnel. Your Plex server never opens a port to the internet. Instead, a tunnel agent on your server creates an outbound connection to the proxy, which handles TLS termination and DDoS protection. Cloudflare Tunnel is free and integrates with their WAF; Tailscale Funnel requires a Tailscale account but provides zero-config WireGuard encryption end-to-end.
- VPN-only access. Run WireGuard or Tailscale on your server and only allow Plex connections over the VPN. This is the most secure option but requires every remote user to install a VPN client, which limits usability for family members who aren’t technical.
- Reverse proxy with nginx/Caddy. If you must open a port, put nginx or Caddy in front of Plex. This lets you add rate limiting, IP allowlisting, and custom TLS certificates. Configure the proxy to forward only the Plex-specific paths and reject everything else.
Plex Account Security
Your Plex account is the keys to the kingdom. If someone compromises your plex.tv credentials, they can access your server remotely, see your watch history, and potentially access other services on your network if Plex has vulnerabilities.
- Enable two-factor authentication. Go to plex.tv → Account → Two-Factor Authentication. Use an authenticator app (TOTP), not SMS. This is the single most important security step.
- Use a unique, strong password. After the 2022 breach, Plex forced password resets, but many users set weak passwords again. Use a password manager and generate a 20+ character random password.
- Check your authorized devices. In Account → Authorized Devices, review every device with access to your server. Remove anything you don’t recognize. Old phones, devices you’ve sold, and test setups accumulate here over time.
- Review your shared users. In Settings → Manage Users, check who has access. Remove ex-friends, former roommates, or anyone who no longer needs access. Each shared user is a potential entry point if their own Plex account is compromised.
Network Isolation
Your Plex server should be isolated from the rest of your home network as much as possible. If an attacker compromises Plex, they shouldn’t be able to pivot to your NAS, your router admin panel, or your workstation.
VLAN separation. Put your Plex server on its own VLAN with firewall rules that only allow: (1) outbound HTTPS to plex.tv for authentication, (2) inbound connections from your media clients on the LAN VLAN, (3) read-only NFS/SMB access to your media storage VLAN, (4) nothing else. If your router supports VLANs (most prosumer and enterprise routers do), this takes 15 minutes to set up and dramatically reduces your attack surface.
Docker network isolation. If Plex runs in Docker alongside other containers, use Docker’s network isolation. Create a dedicated bridge network for Plex and don’t attach other containers to it. This prevents a compromised Plex container from communicating with your database containers, management interfaces, or other services.
Firewall the server itself. On the Plex host, configure iptables or ufw to allow only port 32400 inbound (or whatever port your reverse proxy uses) and deny everything else. If Plex is the only service on the box, drop all inbound traffic except SSH (from a management VLAN only) and the Plex port.
Keep Plex Updated
Plex has had multiple critical security vulnerabilities over the years, including remote code execution bugs in the media scanner, XML external entity (XXE) injection in the DLNA service, and server-side request forgery (SSRF) in the relay system. Plex patches these quickly, but only users who update get the fixes.
If you run Plex in Docker, updating is trivial:
docker compose pull plex
docker compose up -d plex
For automatic updates, use Watchtower — a Docker container that monitors your running containers and automatically pulls and recreates them when new images are published. Set it to check daily and send notifications via your preferred channel.
Disable Services You Don’t Use
Plex ships with several features that increase the attack surface without benefiting most users:
- DLNA. Unless you have a DLNA client (older smart TVs, some game consoles), disable it in Settings → DLNA. The DLNA server has historically been a source of vulnerabilities and exposes an unauthenticated media endpoint on your LAN.
- Plex Relay. When direct connections fail, Plex routes traffic through its relay servers. This works but adds latency and exposes your traffic to Plex’s infrastructure. If you’ve set up a reverse proxy or VPN, disable the relay in Settings → Network → “Enable Relay.”
- Remote access auto-config. Plex tries to automatically configure UPnP port forwarding on your router. Disable this in Settings → Remote Access if you’re using a reverse proxy, and disable UPnP on your router entirely while you’re at it.
Library Permissions and Access Control
Not every shared user needs access to every library. When you share your server with someone, you can select which libraries they see. Use this aggressively:
- Create separate libraries for content you only want certain users to see (e.g., a “Kids” library, a “4K” library for users with sufficient bandwidth)
- Set per-user bandwidth limits to prevent a single user from saturating your upload and causing transcoding for everyone else
- Disable “Allow Downloads” for shared users unless they specifically need it — downloads bypass transcoding and consume full bitrate bandwidth
- Use Plex’s “Managed Users” feature for family members rather than separate Plex accounts, as managed users don’t require their own plex.tv credentials
Monitoring and Logging
You can’t secure what you don’t monitor. Tautulli is the standard tool for Plex monitoring — it tracks who’s watching what, from where, on which device, with detailed connection info. Set up Tautulli notifications for:
- New device connections (someone added a device you don’t recognize)
- Streams from unusual geographic locations
- Multiple simultaneous streams from the same user (possible credential sharing)
- Failed authentication attempts
Combine Tautulli with fail2ban on your reverse proxy to automatically ban IPs that show suspicious behavior — repeated failed auth attempts, port scanning, or known exploit patterns in the request path.
How PlexBeam Improves Security
With PlexBeam, your Plex server never needs to open a port for transcoding — not even 32400. Transcode requests are routed through PlexBeam’s encrypted pipeline to remote GPU workers, and the transcoded stream is delivered directly to the client. Your server’s only job is serving file data over an authenticated, encrypted channel. No inbound ports, no direct exposure, no attack surface beyond the PlexBeam agent running on your machine.