Available inall subroutines.

Converts the IP address (IPv4 or IPv6) to a string.

The Domain Name Service (DNS) is not consulted, so the numeric form is returned.

The inverse conversion is available as std.str2ip.


if (std.ip2str(std.str2ip(req.http.Fastly-Client-IP, "")) ~ my_acl) {

User contributed notes


Do you see an error in this page? Do you have an interesting use case, example or edge case people should know about? Share your knowledge and help people who are reading this page! (Comments are moderated; for support, please contact Fastly support)