The most important difference between TCP and UDP in networking.
Number
TCP
UDP
1
TCP stands for Transmission control protocol
UDP stands for User datagram protocol
2
TCP is connection oriented protocol means before sending data, there is connection establishment happens between two clients
UDP is connectionless protocol means there is no connection establishment before sending data between two clients
3
TCP provides reliable communication
UDP provides unreliable communiation
4
TCP gives gaurantee of transmission of data
UDP does not give gaurantee of transmission of data.
5
TCP header size is 20 bytes
UDP header size is 8 bytes
6
In TCP there is concept of acknowledgment
In UDP there is no concept of acknowledgment
7
TCP has concern of jitter. Means if any packet lost then TCP does not provide subsequent data to the application while it is requesting re-sending of the missing data
UDP does not have concern of jitter because there is retransmission of missing data.
8
TCP is slower as compared to UDP because retransmission of lost packets can take long delay.
UDP is faster as compared to TCP because there is no retransmission of lost packets