UDP

UDP (User Datagram Protocol) is a core transport layer protocol of the internet that provides a simple, connectionless communication service. Unlike TCP, UDP does not establish a connection before sending data and does not guarantee delivery, ordering, or duplicate protection.

Features of UDP

  • Connectionless: No handshake required before data transmission.
  • Low Latency: Faster than TCP due to no connection setup overhead.
  • No Guarantees: Does not guarantee delivery, ordering, or error correction.
  • Broadcast Support: Supports broadcasting to multiple recipients.
  • Lightweight: Smaller header size (8 bytes) compared to TCP.

UDP and Clash

Clash for Windows supports UDP proxying, which is essential for applications like online gaming, video calls, and DNS queries. UDP support can be enabled in the configuration:

  • udp: true: Enable UDP support in the configuration
  • mode: udp: Set proxy mode to handle UDP traffic