Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

earmsby's avatar

Herd - site can't be reached issue

I'm using Herd for local testing of my Laravel apps and haven't had any issues. I just created a new laravel install on a project with the directory name of 'ea-dep-test' and tried to open it in Herd (ea-dep-test.test). I get a "site can't be reached" error with a code of "DNS_PROBE_FINISHED_NXDOMAIN"

I double checked that other projects open just fine such as "acc-study.test" and "pixel-positions.test" work just fine. Is there a problem with using "test" as part of the project name? Or should I be looking for some other problem with my code?

0 likes
6 replies
LaryAI's avatar
Level 58

The "site can't be reached" issue with a "DNS_PROBE_FINISHED_NXDOMAIN" error typically indicates a DNS resolution problem. Since other projects are working fine, the issue is likely specific to the new project setup. Here are some steps you can take to troubleshoot and resolve the issue:

  1. Check Herd Configuration: Ensure that Herd is properly configured to recognize the new project. Sometimes, Herd might not automatically detect new projects, especially if there are configuration issues.

  2. Verify Hosts File: Make sure that the hosts file on your system has an entry for ea-dep-test.test. This is usually managed by Herd, but you can manually check it:

    • On macOS and Linux, the hosts file is located at /etc/hosts.
    • On Windows, it's located at C:\Windows\System32\drivers\etc\hosts.

    You should see an entry like:

    127.0.0.1 ea-dep-test.test
    
  3. Restart Herd: Sometimes, simply restarting Herd can resolve DNS issues. Stop and start Herd again to refresh its configuration.

  4. Clear DNS Cache: Clear your DNS cache to ensure there are no stale entries:

    • On macOS, run sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder.
    • On Windows, run ipconfig /flushdns in the Command Prompt.
    • On Linux, the command can vary, but sudo systemd-resolve --flush-caches is common.
  5. Check Project Directory: Ensure that the project directory ea-dep-test is correctly set up and that the Laravel application is running without errors. You can try running php artisan serve to see if the application starts without issues.

  6. Check for Conflicts: Ensure there are no conflicts with other services or applications that might be using the same domain or port.

  7. Review Herd Logs: Check Herd's logs for any error messages or warnings that might give more insight into the problem.

If none of these steps resolve the issue, consider creating a new Laravel project with a different name to see if the problem persists, which might help isolate the issue further.

earmsby's avatar

The entry is not found in the hosts file. I did try creating a brand new Laravel project with a different name but am still having the same problem.

I think it is related to a problem with Herd Helper since the status is red. It says to change the port if the status is red but I'm not sure how to know what to change it to.

earmsby's avatar

Posting back to this topic in case anyone else runs into this. It turns out it's a problem with Windows disabling the Herd Helper service. With the help of the folks at Herd, I was able to solve it by reinstalling Herd with the latest installer.

2 likes
DominikEller's avatar

For me there were entries in the nginx log regarding missing crt files for older domains. So I deleted the old entries from ~/Library/Application Support/Herd/config/valet/Nginx directory and restarted herd. After that the domains worked again...

1 like
garrettmassey's avatar

@DominikEller Any idea what causes this? It just happened to my setup as well, and seemingly out of nowhere, but I am not sure.

funkyjamma's avatar

I am having this issue on an M4 Mac none of the tips in this thread fix it I still get ERR_CONNECTION_REFUSED

1 like

Please or to participate in this conversation.