In IPv4, localhost uses 127.0.0.1. For IPv6, it uses ::1.