Home / Localhost / localhost:8000

localhost:8000: what runs on it and how to open it

Port 8000 is used by Django, PHP’s built-in server and Python’s http.server. How to open it and fix errors.

localhost:8000 in a browser address bar reaches port 8000 on your computer, where Django, PHP, Python is running

Open this address: http://localhost:8000This opens on your own computer. It only works if the program is running.

localhost:8000 is a very common address for Django, PHP and Python development servers. It only works while the server is running in a terminal on your computer.

What runs on localhost:8000

Commands to start and test port 8000

Django
python manage.py runserver 8000
PHP
php -S localhost:8000
Python static files
python3 -m http.server 8000
FastAPI
uvicorn main:app --reload --port 8000

Find what is using port 8000

Run these in a terminal on your computer. Nothing is sent to this site.

If localhost:8000 will not open

This site can’t be reached (ERR_CONNECTION_REFUSED)
The server is not running. Start it in a terminal and keep that terminal open. See the full checklist.
Port 8000 is already in use
Find what is using it with the tool below, or start on another port, for example runserver 8001.
Invalid HTTP_HOST header (Django)
You opened the site with a host name Django does not know. Add it to ALLOWED_HOSTS in settings.py.
PHP shows a blank page or 404
The folder has no index.php or index.html. Start the server from your project folder.
Works on localhost, not on your phone
Start with 0.0.0.0:8000 and use your computer’s IP address. See how to open localhost from your phone.

Other ports like 8000

PortUsually used by
localhost:3000React, Next.js, Express
localhost:5173Vite dev server
localhost:4200Angular dev server
localhost:5000Flask
localhost:8080Tomcat, Spring Boot, Docker
localhost:8888Jupyter Notebook
localhost:9000PHP-FPM, SonarQube

Questions about localhost:8000

What runs on localhost:8000?
Most often Django (runserver), the PHP built-in server, Python's http.server, or FastAPI with Uvicorn.
How do I stop the server on port 8000?
Press Ctrl+C in the terminal where it is running. If you cannot find that terminal, use the port checker below to find the process and stop it.
Is localhost:8000 safe?
Yes, as long as it stays on localhost. Only your own computer can reach localhost:8000. It becomes reachable from other devices only if you start the program on 0.0.0.0 or your computer's IP address. Development servers are for testing, so do not put them on the public internet.
Can I use a different port instead of 8000?
Yes. Most programs let you choose the port with a setting or a command option. Pick a free port above 1024 and open that number instead, for example localhost:8001.
How do I check what is using port 8000?
Use the port checker on this page. It shows the command for Windows, macOS and Linux and does not send anything to this site.
Can I open localhost:8000 from my phone?
Yes, if both are on the same Wi-Fi. Start the program so it listens on all addresses, then open your computer's IP address with :8000 on the phone. A firewall on the computer can still block it.

Updated 2026-10-02

Free tools that help

Related pages