The MERN stack (MongoDB, Express, React and Node.js) lets you write a whole web application in JavaScript. This manual is the short version: the learning path, the modern setup for 2026, what "advanced" MERN really involves, and where to deploy. Each step links to a detailed guide on this knowledge base.
For the complete learning path, a starter project, the production checklist and the full list of tutorials, see the MERN stack resource index. This page summarises it.
Learn JavaScript well, then React (create projects with Vite, not Create React App), then Node.js with Express 5, then MongoDB with Mongoose. Build one small app end to end before adding authentication, real-time features or tests. Deploy the Node.js API on the Domain India App Platform (Node.js is detected automatically; the included database is PostgreSQL, so use a hosted MongoDB) or on a VPS where you run MongoDB yourself.
1. What changed since older MERN tutorials
Many MERN guides online are out of date. Check a tutorial against this list before you follow it.
| Older tutorials say | Use this in 2026 |
|---|---|
npx create-react-app my-app | npm create vite@latest my-app -- --template react; Create React App is deprecated |
The mongo shell | mongosh, the current MongoDB shell |
| Express 4 route syntax | Express 5, the current major version; some route patterns changed |
| Any Node.js version | The current Node.js LTS release (Node.js 24 in September 2026) |
| Heroku free dynos | There is no free Heroku tier; see section 4 for where to deploy |
2. The learning path
- JavaScript first.Functions, arrays and objects, modules, promises and async/await. Add the command line and Git.
- React.Components, props, state, hooks, forms, React Router and fetching data from an API.
- Node.js and Express.Routes, middleware, error handling, environment variables and a clean folder structure.
- MongoDB and Mongoose.Schemas, validation, indexes and relationships between documents.
- One full-stack project.A to-do list or event app that goes from React, through the API, to the database and back.
Hands-on tutorials: a to-do list app with MERN and an event management app with MERN.
3. The "advanced" topics, in a sensible order
Once one app works end to end, add these one at a time:
- Authentication and roles. Hash passwords with bcrypt or argon2, use secure cookies or short-lived tokens, and check roles on the server, never only in React. See MERN user authentication with OAuth 2.0.
- Security. Validate all input on the server, set security headers (for example with Helmet), restrict CORS to your own domain and rate-limit login routes. See OWASP Top 10: practical defence for PHP and Node.js.
- State management. React's own state and context cover most apps. Reach for Redux Toolkit or a data-fetching library such as TanStack Query only when shared state becomes hard to manage.
- Real-time features. WebSockets (for example Socket.IO) for chat or live updates.
- Testing. Unit tests with Vitest or Jest, API tests with Supertest, and browser tests with Playwright.
- CI/CD. Run the tests on every push with GitHub Actions, then deploy.
Is MongoDB right for your data? For strongly relational data such as accounts, invoices and stock, PostgreSQL or MySQL is usually a better fit, and the Express and React skills stay the same. See choosing between PostgreSQL, MySQL, SQLite and MongoDB.
4. Where to run a MERN app on Domain India
| Option | Node.js API | MongoDB | Good for |
|---|---|---|---|
| App Platform | Detected automatically from package.json | Not included (PostgreSQL is); use a hosted MongoDB and test the connection from your app | Most MERN apps |
| VPS | You install and run it, for example with PM2 or systemd | You install it on the same server | Full control |
| cPanel or DirectAdmin shared hosting | The panel's Node.js tool, for small apps | Not available; port 27017 is not open outbound | React plus Express with MySQL |
The App Platform has no automatic deploy on push: deploy with Deploy Now, or with a deploy token from your terminal or CI, using the commands shown in the client area. Before going live, work through the production checklist in the MERN resource index. A VPS is self-managed, without cPanel. The step-by-step guides are getting started with the App Platform, running MERN on a clean VPS and MERN on shared hosting.
Prices on the cards are Domain India list prices on 19 September 2026, excluding 18% GST.
- 512 MB RAM per app
- 1.5 GB RAM total
- 2 vCPU
- 10 GB NVMe SSD
- 1 vCPU
- 2 GB DDR4 RAM
- 64 GB NVMe SSD Storage
- 2 TB Monthly Bandwidth
What is the MERN stack?
MERN is MongoDB, Express, React and Node.js. MongoDB stores the data, Express on Node.js provides the API, and React builds the interface, so the whole application is written in JavaScript.
Should I still use Create React App?
No. Create React App is deprecated. Create the React part of a new MERN project with Vite, or use a framework such as Next.js if you need server rendering.
Can I host a MERN app on the Domain India App Platform?
Yes. The App Platform detects Node.js apps automatically. It includes PostgreSQL rather than MongoDB, so connect to a hosted MongoDB and test the connection from your deployed app, or switch to the included PostgreSQL.
Can I run MongoDB on Domain India shared hosting?
No. Shared hosting has no MongoDB server, and the outbound firewall on our cPanel and DirectAdmin servers does not open MongoDB's port 27017. Use a VPS or the App Platform, or use MySQL on shared hosting.
Which Node.js version should I use for a new MERN project?
Use the current Node.js LTS release, which is Node.js 24 in September 2026.
Ready to build? Follow the MERN resource index, then deploy on the App Platform or a VPS.
Node.js apps are detected and built automatically, with free SSL and a PostgreSQL database included.
See the App Platform