The Internet Control Message Protocol (ICMP) is the protocol used by network devices to send error messages and operational information.

Ping (Echo Request/Reply)

When you ping a server, you send an ICMP Type 8 packet. The server replies with a Type 0 packet. The time it takes is your latency.

Unreachable Destinations

If a router cannot find a path to your destination, it sends an ICMP "Destination Unreachable" message back to your computer. Without ICMP, your browser would just spin forever without knowing why the site failed.

For security, many firewalls block ICMP, which is why some servers won't respond to pings even if they are online.