Host

The authority that the request is intended for.

Fastly reads this header from requests. It is defined by an external standard.

Fastly hosts multiple customer services on the same set of IP addresses, and in most cases uses the Host header to identify the service that should handle a request (the main exception to this is customers that have purchased dedicated IP address space and pinned the dedicated IPs to a specific service).

Multiple domains can be associated with a Fastly service. A common use case for the Host header inside a service configuration is to canonicalize the host:

if (req.http.host !== "example.com") {
error 600; # Trigger an error in order to redirect to example.com
}

In many cases, backend servers are also operated in a similar manner, and require a specific Host to be provided in order to serve the correct content or invoke the correct process (as is the case for providers such as Heroku, AWS S3 or Google Cloud Storage).