Join 1M+ other developers and:
- Get help and share knowledge in Q&A
- Subscribe to topics of interest
- Get courses & tools that help you grow as a developer or small business owner
How to deploy MERN Stack
I have a MERN app with MongoDB Atlas as my database. Both backend and the frontend is in a folder call MyApp. In my My App folder, I have a server.js with express and cors and API routes and other stuffs. Also in the MyApp folder, I have a folder called frontend which is a React App. I have test locally and works well. HTTP://localhost:5000 is my backend API and http://localhost:3000, is the frontend React App. I have already setup Nginx and PM2.
Next, how do I deploy this MERN stack to a droplets. Many thanks in advance.
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.×