DEV Community

Rohit Urane
Rohit Urane

Posted on

1 1

Host your laravel application on Heroku for free.

Image description

Host your testing laravel application on Heroku for free.

Do you want to #host your laravel application on Heroku? You are going with a new setup of the laravel application.

Creating Laravel application on Local System

First, I am installing the laravel application on the local development system through composer.

composer create-project --prefer-dist laravel/laravel herokuApp
Enter fullscreen mode Exit fullscreen mode

Make Procfile inside the root folder of your project

After completing the installation, create a file of the name Procfile and insert the below code. This file is a configuration file for Heroku.

web: vendor/bin/heroku-php-apache2 public/
Enter fullscreen mode Exit fullscreen mode

Download and login to the Heroku platform from the command line

For that, you need to install Heroku CLI on your system. Go to the Heroku platform and download & install it. Click Here. Run the below command inside your project folder.

heroku login
Enter fullscreen mode Exit fullscreen mode

It will open a browser window to log in to Heroku. If you don't have an account on Heroku, create it first.

Read More

Heroku

This site is built on Heroku

Join the ranks of developers at Salesforce, Airbase, DEV, and more who deploy their mission critical applications on Heroku. Sign up today and launch your first app!

Get Started

Top comments (0)

Billboard image

Create up to 10 Postgres Databases on Neon's free plan.

If you're starting a new project, Neon has got your databases covered. No credit cards. No trials. No getting in your way.

Try Neon for Free →

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay