Resolving Common Issues

If you are on this site, we’re sorry. We are working to create the most robust and easiest to use local development environment for Laravel – but Herd is still a tool early in its lifecycle, and we aren’t there yet. On this page, you’ll find common issues and a solution to resolve them.

If the documentation and the following tips don’t resolve your issue, please head over to the support section.

Restarting Herd

In some rare scenarios, Herd doesn’t start after it has been quit previously. Please check your Task Manager if there are still running instances of Herd and stop them manually before opening Herd again.

Herd Debug Logs

The Herd app writes all output to a main.log log file but keeps this file to a maximum of 1MB, so if you want to get the debug information for Herd, you can check this file. If you encounter a problem that you can reproduce, please check the logs and share them with us via the support if you can’t fix the problem with this information.

%USERPROFILE%\AppData\Roaming\Herd\logs\main.log

404 Errors

If Herd can not properly detect a driver for your site or can’t find the site at all, Herd displays a custom 404 error page. This error page mostly has a useful hint how to fix the problem but it case it does not, the most common problem is that the directory of the project includes www in the name.

Herd strips www from directory names so that all sites are accessible via their domain with and without www prefix.

The solution to this is renaming the directory from www.your-site.com to your-site.com. This allows yout to access the site at http://your-site.com.test. If the site had specific configurations, you need to apply them again after this change because Herd treats this site as a new one.

Bad Gateway

These errors happen if there is something wrong with the nginx web server. This could be an old PHP process or a broken configuration file. A good practice to fix the config file for a single site is by isolating the site to a specific PHP version or securing it with a TLS certificate. You can always switch back to the previous PHP version or unsecure the site but all these commands regenerate the configuration file to fix the issue.

You can access the individual configuration files for nginx at the following path:

%USERPROFILE%\.config\herd\config\valet\Nginx

If this does not help, please create an issue with the broken config file in the community repository.

DNS Errors

While the macOS version of Herd is running dnsmasq as a local DNS server, the Windows version regularly updates the hosts file of your machine. It’s located at the following path:

C:\Windows\System32\drivers\etc\hosts

If everything works as expected, the HerdHelper Windows Service writes something like this to the file:

# Herd generated Hosts. Do not change.
127.0.0.1 database.herd.test
127.0.0.1 your-site.test
# End Herd generated Hosts

This tells your browser to look for these domains on your local machine and redirect them to nginx from Herd. If you don’t see the generated hosts in your hosts file, there is something wrong with the HerdHelper.

The HerdHelper Windows Service isn’t working

There are many reasons why Herd can’t write to your hosts file, sometimes it’s locked by anti virus software or is simply read-only. The HerdHelper tries to mitigate these situations automatically but can also write logs to track down the issue, so if the helper works and the status is green, please check these logs.

If the helper doesn’t start, please try starting it by changing the port or via your Windows Services or even by starting it manually at the following path:

%USERPROFILE%\.config\herd\bin\HerdHelper.exe

Starting it manually reveals a terminal window with logs and should help debugging the issue.