How to Use curl to Print the Location Header in a Response?

18 Replies, 781 Views

Solid solution! For curl print location header, I’d recommend checking out `xh` (a modern curl alternative). It’s super user-friendly and has built-in support for redirects and headers.

```bash
xh --headers http://example.com | grep location
```

Might be worth a try if you’re tired of curl’s quirks.

Messages In This Thread



Users browsing this thread: 1 Guest(s)