HTTPfy

Port 8000 (HTTP alternate / Django dev)

Django runserver, python -m http.server, uvicorn/FastAPI examples, Splunk web and many apps' internal HTTP ports.

Registered (user) port, 1024-49151 TCP Development tools Expose only to trusted sources

What port 8000 is used for

Django runserver, python -m http.server, uvicorn/FastAPI examples, Splunk web and many apps' internal HTTP ports.

Security: should port 8000 be open?

Expose only to trusted sources. Development servers should stay on localhost. python -m http.server on 0.0.0.0 shares the whole directory with anyone who can reach it.

IANA assignment

Service nameProtoDescriptionAssigneeReference
irdmi TCP iRDMI Gil Shafriri -
irdmi UDP iRDMI Gil Shafriri -

Check what is listening on port 8000

Linux: is anything listening on TCP 8000?
sudo ss -tlnp 'sport = :8000'
Linux / macOS: which process owns the port
sudo lsof -nP -i :8000
Older Linux / BSD (net-tools)
sudo netstat -tlnp | grep ':8000 '
Windows (Command Prompt)
netstat -ano | findstr :8000
Windows (PowerShell)
Get-NetTCPConnection -LocalPort 8000 -State Listen | Select LocalAddress,OwningProcess

Test it from outside

From another machine
nc -vz -w 5 HOST 8000
From Windows
Test-NetConnection HOST -Port 8000

Allow only trusted sources on port 8000 in the firewall

Replace 203.0.113.10 with the address or network you trust. With ufw, make sure the default incoming policy is deny.

ufw (one trusted source)
sudo ufw allow from 203.0.113.10 to any port 8000 proto tcp
iptables
sudo iptables -A INPUT -p tcp --dport 8000 -s 203.0.113.10 -j ACCEPT
sudo iptables -A INPUT -p tcp --dport 8000 -j DROP
nftables
sudo nft add rule inet filter input ip saddr 203.0.113.10 tcp dport 8000 accept
sudo nft add rule inet filter input tcp dport 8000 drop
Windows Firewall
New-NetFirewallRule -DisplayName 'TCP 8000 trusted' -Direction Inbound -Protocol TCP -LocalPort 8000 -RemoteAddress 203.0.113.10 -Action Allow

Related ports

All port numbers · Open port checker
Assignment data: IANA port number registry (public domain), retrieved 2026-11-10.