Compare between TCP and UDP

TCP/IP UDP
Connection-Oriented Protocol Connectionless Protocol
More Reliable Less Reliable
Slower Transmission Faster Transmission
Packets order can be preserved or can be rearranged Packets order is not fixed and packets are independent of each other
Uses three ways handshake model for connection No handshake for establishing the connection
TCP packets are heavy-weight UDP packets are light-weight
Offers error checking mechanism No error checking mechanism
Protocols like HTTP, FTP, Telnet, SMTP, HTTPS, etc use TCP at the transport layer Protocols like DNS, RIP, SNMP, RTP, BOOTP, TFTP, NIP, etc use UDP at the transport layer