All the necessary commands use to deploy will be there in this article.


  1. Node.js and npm installed.
  2. Node.js and MongoDB application.
  3. Free Heroku account.
  4. Heroku CLI.
  5. GitHub account.
  6. Git (Not necessary but it’s best to push code to github using git bash).

Important lines of code to check before moving ahead.

  1. Specify the version of the node in package.json file-:

(Find you node version by typing node --version in command prompt)

"engines": {
"node": "14.X"

2. specify the start command in the package.json file-: ex nodemon, nodemon server.js, npm start, etc.

"scripts": {
"start": "nodemon server.js"

(From 2013 procfile is not necessary for node app and it…

Umang Agrawal

Umang is a developer, tech enthusiast, and a photographer. Loves to code with coffee on desk.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store