Question

Can I deploy a PERN(Postgres,Express,React,Nodejs) stack web app to Digital Ocean? How much will it cost?

I am made a Pern stack app for a school which can perform crud operations. The database is Postgres and it will have 10 tables and approximately 2000 rows for each table. How much will hosting this app cost monthly?


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.

Accepted Answer

Hi there,

Yes, this tech stack could be set up on a single $5/mo Droplet. However the size of the server would depend on the complexity of the app, the amount of traffic and the resources that the app needs.

What I usually suggest is:

  • Setup a small Droplet
  • Configure it by installing all of the necessary services
  • Then deploy your app
  • Finally, run some load tests as per this tutorial here:

https://www.digitalocean.com/community/tutorials/an-introduction-to-load-testing

That way you will be able to tell how much traffic your app can handle with the resources that you’ve selected.

If you see any bottlenecks like CPU or RAM, then you could upgrade the Droplet accordingly. This way you would know how much traffic you can handle and be ready for production.

In case that you need this, there are a lot of resources on the DigitalOcean community site that would help you with the installation and configuration of the Droplet. For example:

https://www.digitalocean.com/products/managed-databases/

  • Here is how to set up Node.js for production on an Ubuntu server:

https://www.digitalocean.com/community/tutorials/how-to-set-up-a-node-js-application-for-production-on-ubuntu-20-04

  • Here is also a quick video on how to do that too:

Hope that this helps. Best, Bobby