How to create new project with Laravel Herd?

Ahmad Rosid - Sep 15 - - Dev Community

Did you know that Laravel, the popular PHP framework, and Herd, a new macOS-native development environment, make a powerful combination for web developers. In this tutorial, we'll walk you through setting up a Laravel project using Herd, streamlining your development workflow.

What is Herd?

Herd is a native macOS application that manages your entire PHP stack, including:

  • Nginx
  • MySQL
  • Multiple PHP versions

Unlike traditional setups, Herd doesn't rely on Docker or virtual machines, offering improved performance and resource efficiency.

You can download Laravel Herd here. It's the best app for those who are just getting started with Laravel.

Note: You can use laravel herd in Windows now and soon it will on linux.

Why Use Herd for Laravel Development?

Before Herd, you needed to install a lot of things to start working with a Laravel project: PHP, Composer, Node.js, and more. But with Laravel Herd, you can do all that with a single click. It significantly simplifies the setup process, allowing you to focus on development rather than configuration.

Key benefits of using Herd include:

  1. Quick Setup: Start new Laravel projects in minutes.
  2. Native Performance: Run your stack without virtualization overhead.
  3. Version Flexibility: Easily switch between PHP versions.
  4. Laravel Ecosystem Integration: Seamless compatibility with other Laravel tools.

Creating a new Laravel project

Go to your top left bar window if you on mac and top bar left if you are using windows.

Open herd

Then click sites.

You will see new window being open like this.

Sites window

Now click plus icon on the top of that sidebar.

Add project

Then click laravel or you can link your custom project folder.

Now choose your starter kit, I like to use Laravel Jetstream.

Choose starterkit

You can now configure the options. Each starter kit will have different configurations. Personally, I prefer these settings.

Configure starter kit

Then click next. And wait.

Create log

After it done you can now open the url or open your IDE and more.

Done

In this example, I can open a browser with the following URL: http://blog-project.test/.

And your project is created.

Image description

If you go back to your Herd sites window, you can click the "Action" button, which provides quite useful shortcuts to manage your project.

Image description

. . . . . .
Terabox Video Player