Fastly's Varnish is based on Varnish 2.1 and our Varnish syntax is specifically compatible with Varnish 2.1.5. The principal configuration mechanism of Varnish software is the Varnish Configuration Language (VCL), the scripting language used to configure and add logic to Varnish caches. Fastly has included a number of extensions to VCL that won't be covered by any other documentation.
Functions available in Fastly VCL.
VCL variables supported by Fastly.
Fastly VCL supports variables for storing temporary values during request processing.
Fastly VCL provides various arithmetic and conditional operators.
Fastly VCL is a statically typed language. Several types are available.
Fastly's directors contain a list of backends to direct requests to.
Fastly VCL provides access to rounding modes by way of independent functions for rounding values.
VCL Snippets are short blocks of VCL logic that can be included directly in your service configurations.
Dynamic VCL Snippets are versionless sections of VCL logic that can be inserted into your service configuration without requiring custom VCL. API only.
Regular VCL Snippets are versioned sections of VCL logic that can be inserted into your service configuration without requiring custom VCL.
Create your own Varnish Configuration Language (VCL) files with specialized configurations.
Upload custom VCL files to use custom VCL and Fastly VCL together at the same time.
Preview and test custom VCL prior to activating a new version of a service.
Functions for selecting a response from common content negotiation request headers.
Functions for cryptographic- and hashing-related purposes.
Variables and functions that provide flexibility when dealing with dates and times.
Variables that allow you to track and control requests with ESI.
Floating point classification functions.
Variables that provide the ability to search a geolocation database for a given host or IP address.
Features that support various math constants and limits.
Rounding of numbers.
Miscellaneous features that don't easily fit into other categories.
Functions for query string manipulation based on Dridi Boukelmoune's vmod-querystring for Varnish.
Functions that support the insertion of random strings, content cookies, and decisions into requests.
Variables related to controlling range requests via Segmented Caching.
Variables relating to the server receiving the request.
Variables that give more insight into what happened in a request.
Functions manipulating strings of arbitrary text.
Functions that provide a means to declare a constant dictionary and to efficiently look up values in the dictionary.
Variables that provide TCP information.
Variables that expose information about the TLS and HTTP/2 attributes of a request.
Functions that provide interfaces for generating and validating unique identifiers.