Open hosts file. On Windows, it’s usually located at C:WindowsSystem32driversetchosts, while on macOS and Linux, it’s found at /etc/hosts.
Add a New Entry: 127.0.0.1 yourlaravelapp.test
Add a Virtual Host Configuration:
Windows, it’s usually located at C:xamppapacheconfextrahttpd-vhosts.conf. On macOS, it’s typically located at /Applications/XAMPP/etc/extra/httpd-vhosts.conf.
2
Answers
Open hosts file. On Windows, it’s usually located at C:WindowsSystem32driversetchosts, while on macOS and Linux, it’s found at /etc/hosts.
Add a New Entry: 127.0.0.1 yourlaravelapp.test
Add a Virtual Host Configuration:
Windows, it’s usually located at C:xamppapacheconfextrahttpd-vhosts.conf. On macOS, it’s typically located at /Applications/XAMPP/etc/extra/httpd-vhosts.conf.
And after that restart apache
First, open your
hosts
file,C:WindowsSystem64driversetchosts
etchosts
Add below line in
hosts
file,Configure your Apache in
httpd-vhosts.conf
,And then restart your xampp, now you can access using
yourvirtualhost.name
.