Step 8
Heroku is a cloud platform as a service (PaaS) that enables you to easily deploy your server. By taking care of most things related to deployment, Heroku makes it easy to get your server up and running.
Before we get started, you must create a free Heroku account (sign up).
Login to your Heroku account and create a (free) Heroku app.
Give your app a name. You must come up with a unique one.
Once the app is created, open the Deploy tab. Select GitHub under the Deployment Method.
You may be redirected to GitHub to authorize Heroku. Once authorized, Heroku can read your GitHub repositories. In Heroku, select the repository that holds the source code of your app.
Your GitHub repository is now connected to your Heroku App. It makes things easier to enable automatic deployment, so the server is deployed on every push to the main
branch.
Finally, go to the settings to select a "build pack."
Among the options, choose "NodeJS" and save the changes.