curl -H 'Host: example.com' http://localhost

Category: Self-Hosting

curl -H 'Host: example.com' http://localhost

Test Nginx virtual host routing by spoofing the Host header from the command line

Tests Nginx virtual host routing by sending a request to localhost but with a fake Host header. Nginx routes based on Host — this simulates how it handles a real request.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.