Hosting PHP apps at Heroku, with caveat

If you’re looking for a free place to host a PHP app with modest load demand, Heroku works with the important caveat that some commonly-available libraries (such as ZLib for compression) are not available to your app.

The process is simple enough. The only two ‘gotchas’ we ran into are

1. When you create the app at Heroku, be sure to specify the cedar stack, thusly:

2. If your root app filename is not index.php, you have to add a file named index.php or Heroku will reject the push when you ‘git push heroku’.


By the way, we were also exploring PHPfog.com for hosting PHP files. It looks like a great system, however PHPfog has a severe (imo) limitation for their free shared hosting, whcih is they do not permit an app to fopen a remote url… so an app cannot, for example, open an image created by Google API (such as a QR code) and embed that in a PDF.

This entry was posted in Uncategorized. Bookmark the permalink.

One Response to Hosting PHP apps at Heroku, with caveat

  1. Eric says:

    Thank you for #2! I was almost doubting that heroku even supported php.