Did you mean to visit localhost:3000?

Did you mean to visit: http://localhost:3000/?

💡 Pro Tip: Port 3000 is the default for React and Express apps. If you get "port already in use" errors, try using PORT=3001 or kill the existing process.

Quick Commands for Port 3000

Find what's using port 3000:
lsof -i :3000 (Mac/Linux)
netstat -ano | findstr :3000 (Windows)
Kill the process:
kill -9 PID (Mac/Linux)
taskkill /PID PID /F (Windows)

About Port 3000

Port 3000 is commonly used by:

Common Issues with Port 3000

"Port 3000 is already in use"

This error occurs when another application is already using port 3000. Solutions:

  • Find and close the application using port 3000
  • Use a different port by setting an environment variable:
    • React: PORT=3001 npm start
    • Express: Change the port in your code
  • On Windows, you can find and kill the process: netstat -ano | findstr :3000 then taskkill /PID [PID] /F

✅ Quick Solution

Start React on a different port: PORT=3001 npm start

"Cannot connect to localhost:3000"

If your application is running but you can't connect:

  • Check if your application is actually running
  • Make sure you're not using HTTPS when the server is HTTP
  • Try using 127.0.0.1:3000 instead of localhost:3000
  • Check if a firewall is blocking the connection

Useful Resources