Question

how to go to localhost 3000

i want to check if my sever is working and i have to go to localhost 3000 to see it


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Check here and see if your port is closed or open. If necessary, you should open your port through the firewall.

Hi @althafnash,

If you deploying the application on a DigitalOcean droplet, you’ll need to allow port 3000 to have incoming connections first. If you are using UFW on your droplet, you can use:

sudo ufw allow 3000/tcp

If you are using IPTables, you can do the following:

sudo iptables -A INPUT -p tcp --dport 3000 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT
sudo iptables -A OUTPUT -p tcp --sport 3000 -m conntrack --ctstate ESTABLISHED -j ACCEPT

Once you know your firewall allows connections on port 3000 and you have started your application on that port, you should be able to load it with your droplet’s IP Address;

XXX.XXX.XXX.XXX:3000

Where XXX.XXX.XXX.XXX is your IP address.

Now, there is a better way to do so. You can install Nginx and use it as a reverse proxy to port 3000. That way you can add a domain and once someone loads your application on the domain it will redirect them to port 3000 behind the scenes. Here is an article on how to firstly installed Nginx:

https://www.digitalocean.com/community/tutorials/how-to-install-nginx-on-ubuntu-20-04

Then you can see in the tutorials section a bunch of Nginx Reverse proxy guides which you can follow depending on the app you are developing.

Now, if you are developing your application locally, on your computer and you want to see your progress. You’ll need to install the thing your app is working with. Let’s say you are using Node, you’ll need node installed locally, in order to make your app work locally as well.

Regards, KFSys