Step 1

Login to your Heroku account and create a (free) Heroku app.

Give your app a name. Most names are already be taken! You must come up with a unique one.

Once the app is created, connect it to your GitHub Account.

You must now select the repository that holds the source code of your app.

App is connected now:

Enable Automatic Deploys.

From this point on, every time you push to main, it will be deployed to the Heroku.

Notice that GitHub has changed the default branch name from master to main about 11 days ago! (Read their announcement here). Heroku had updated their default branch for deployment (from master to main) before GitHub doing this. If you are wondering why, read this article: Regarding Git and Branch Naming.