Curl multiple URLs

October 23rd, 2006 toydi Posted in curl, Network, xargs | Hits: 51467 | 2 Comments »

A previous post talked about the usage of curl to request a single URL and display its response header fields. It’s good to know that curl also accepts multiple URLs as arguments.

To display response header information of several URLs:

curl -I http://linuxbyexample.co.nr http://lne.blogdns.com/lbe

When there is a long URL list in a file, use xargs instead:

xargs curl -I < url-list.txt 

2 Responses to “Curl multiple URLs”

  1. xargs: unterminated quote

  2. mithril knight Says:

    around two years later but.

    write the urls with ”

    “http://page1.com”
    “http://page2.com”
    “http://page3.com”

    and so on.

Leave a Reply