HTTP · Inspect requests with curl

Print only the status code

Discard the body and print the HTTP status.

curl -s -o /dev/null -w "%{http_code}\n" https://example.com

Official HTTP documentation

More inspect requests with curl commands

All inspect requests with curl commands · HTTP cheatsheet

Was this page helpful?