localhost:3000

The address of a development server running on your own computer, on port 3000. Node.js, React, Next.js and Rails all use it by default.

Updated November 2026 · 4 min read

The short version: http://localhost:3000 only works while a program on your computer is listening on port 3000. If the page will not load, the dev server is not running, it crashed, or it started on another port because 3000 was taken. Start the server, read the address it prints in the terminal, and open exactly that.

Used by
Node.js, Express, Next.js, Create React App, Rails, Grafana
Full address
http://localhost:3000
Reachable from
Your own computer only
Most common problem
No server running, or the port is already taken

What is localhost:3000?

localhost is a name for the computer you are sitting at. It resolves to the loopback address 127.0.0.1 (or ::1 over IPv6), so a request to it never leaves your machine. The number after the colon is the port: one computer can run many network programs at once, and the port says which of them should answer.

Port 3000 has no official owner. It became a habit because the Express documentation used it in its first example, and the tools that came later copied it. It is above 1023, so a program can open it without administrator rights, and nothing built into the operating system uses it.

So localhost:3000 is not a website on the internet. It is whatever you started on your own machine. Nobody else can open your localhost:3000, and you cannot open theirs.

What runs on port 3000

These tools listen on port 3000 unless you tell them otherwise. The last column shows how to move each one to a different port.

ProgramHow it startsChange the port
Express / plain Node.jsWhatever the code passes to app.listen(), 3000 by conventionChange the number, or read it from process.env.PORT
Next.jsnext devnext dev -p 3001. If 3000 is busy it moves to the next free port by itself
Create React Appnpm startPORT=3001 npm start. It asks before using another port
Ruby on Railsbin/rails serverbin/rails server -p 3001
Nuxtnuxt devnuxt dev --port 3001
Docusaurusdocusaurus startdocusaurus start --port 3001
GrafanaRuns as a servicehttp_port in grafana.ini

Why localhost:3000 will not load

  • Nothing is running. The browser shows "localhost refused to connect" (ERR_CONNECTION_REFUSED) when no program is listening on the port. Closing the terminal, or a crash on startup, stops the server.
  • The server started on another port. Next.js quietly moves to 3001 when 3000 is busy. The terminal prints the real address.
  • Another program already has port 3000. The second server fails with EADDRINUSE: address already in use :::3000. Often it is an old copy of the same dev server still running in a forgotten terminal tab.
  • You typed https. Dev servers speak plain HTTP unless you set up a certificate. https://localhost:3000 then fails with ERR_SSL_PROTOCOL_ERROR.
  • The server runs in a container or virtual machine. It must listen on 0.0.0.0 inside the container, and the port must be published (docker run -p 3000:3000), or your browser cannot reach it.
  • localhost resolved to IPv6. Scripts and proxies on Node.js 17 or later may try ::1 first. If the server listens only on 127.0.0.1, the error reads ECONNREFUSED ::1:3000.

Find what is using port 3000

One command shows whether a program is listening on the port, and which one. No output means nothing is listening, and that is exactly when the browser says the connection was refused.

Finding the program on port 3000 and stopping it. The process ID 48213 is an example: use the one your own command prints.

On Linux, ss -ltnp | grep :3000 gives the same answer. Add sudo on macOS or Linux to see programs owned by another user. Stopping a process ends whatever it was doing, so check what it is before you stop it.

How to fix it

If the page will not load

  1. Look at the terminal where you started the server. If it shows an error, the server is not running: fix that error first.
  2. Find the line that says where it is listening (for example Local: http://localhost:3001) and open that exact address.
  3. Use http://, not https://.
  4. Try http://127.0.0.1:3000. If that works and localhost does not, the server is bound to IPv4 only.

If the port is already in use

  1. Find the program holding the port with the commands in the section above.
  2. If it is an old dev server, stop it (Ctrl+C in its terminal, or end the process by its ID).
  3. If it is something you need, start the new server on another port using the table above.

From localhost to production

Port 3000 is a development habit. In production the same app usually sits behind a web server or load balancer that answers on ports 80 and 443, and visitors never see the number. That is also the point where a crash stops being a message in your terminal and becomes an outage somebody else finds first.

To test a deployed address by hand, the free bulk URL status checker shows the status code and redirects for a list of URLs, and Is Website Down checks one from several countries. Neither can see localhost: like any service on the internet, they only reach public addresses.

Deployed it? Watch the public URL.

Pulsetic is website uptime monitoring. It cannot reach localhost, but once your app is live it checks the public URL from outside your network, confirms any failure from another region, then emails you.

10 monitors free, checked every 5 minutes, with email alerts on failure and recovery. No credit card.

Sources and further reading

The documentation and specifications this guide is written from.

Frequently asked questions

  • Is localhost:3000 a real website?

    No. It is an address on your own computer. It shows a page only while you are running a program that listens on port 3000, and nobody else can open it.

  • Why does it say "localhost refused to connect"?

    Because nothing is listening on port 3000. Start your dev server, check the terminal for errors, and open the address it prints. See the full guide to localhost refused to connect.

  • How do I open localhost:3000 on my phone?

    Use your computer's local network address instead of localhost, for example http://192.168.1.20:3000, with both devices on the same Wi-Fi. The server has to listen on all interfaces (0.0.0.0), and your firewall has to allow the port.

  • How do I change port 3000 to something else?

    Most tools take a flag or an environment variable: next dev -p 3001, PORT=3001 npm start, bin/rails server -p 3001. In plain Node.js or Express, change the number passed to listen().