HTTP HEAD request

Monica Powell
February 28, 2020 🍿 2 min read

Some common HTTP requests are DELETE, GET, PATCH, POST, PUT. However, there are other valid HTTP requests such as CONNECT, HEAD, OPTIONS and TRACE.

I learned more about HEAD request while adding support for HEAD requests to a GET endpoint. An HTTP HEAD request is similar to a GET request but it only cares about the header response to a request and ignores the body that was sent. A HEAD request can be made to determine whether or not a cache resource is stale or not or get additional information about a resource from its response headers alone (for e.g., it's size or whether or not it exists). Since a body isn't returned HEAD requests require less bandwith than similar GET requests.

Learn more at: HTTP - METHODS - HEAD | MDN

LinkedIn

Subscribe to Newsletter

Thanks for reading "HTTP HEAD request". Consider joining my newsletter to receive messages about new content, my thoughts on the web and learn about exclusive opportunities.

     

    I won’t send you spam. Unsubscribe at any time.