Here is a simple guide on how to host a static website on Heroku git repository. To do this you will need a user account on Heroku. If you do not have one already please register one before you continue reading.
Once you login to your Heroku account the first thing you need to do is to create project/app. In our example we are going to call our app “mysite”. Note, your app must have unique name !
Next clone your local app development:
At this stage navigate to your mysite directory ( your directory name will be different ):
Create your simple index.html file:
Since Heroku will allow you host only applications you need to wrap your index.html into PHP index.php file:
Next, add your files to git repository and commit code:
1 2 3
At this point your are done with uploading. Navigate to your Heroku repository URL using your browser and you should see “My site on heroku git repository” as a front page.