Skip to content
Go to file

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Crystal Heroku Buildpack

You can create an app in Heroku with Crystal's buildpack by running the following command:

$ heroku create myapp --buildpack

The default behaviour is to use the latest crystal release. If you need to use a specific version create a .crystal-version file in your application root directory with the version that should be used (e.g. 0.17.1).


In order for the buildpack to work properly you should have a shard.yml file, as it is how it will detect that your app is a Crystal app.

Your application has to listen on a port defined by Heroku. It is given to you through the command line option --port and the environment variable PORT (accessible through ENV["PORT"] in Crystal). However, most web frameworks should handle this for you.


To test a change to this buildpack, write a unit test in tests/run that asserts your change and run make test to ensure the change works as intended and does not break backwards compatibility.

More info

To learn more about how to deploy a Crystal application to Heroku, read our blog post.

Older versions of Crystal

If you have and older version of Crystal (<= 0.9), that uses the old Projectfile way of handling dependencies, please upgrade :-).

You can’t perform that action at this time.