Some applications require reliable ordered delivery of packets. The TCP protocol provides this capability. It uses error detection, retransmissions and acknowledgements. This protocol cares about your data.
Other applications don’t care if every packet is received. These applications can take advantage UDP’s lower overhead to enable faster transmissions.
Typical TCP applications include email and web browsing and typical UDP applications include VoIP and music streaming.
TCP is strictly used for point to point or unicast transmissions while UDP can also be used for multicast and broadcast transmissions.
TCP and UDP Headers
The header added to messages by the Transport layer includes more than just the source and destination port numbers. Here we are showing all the information included in TCP and UDP headers.
Note how the TCP protocol requires more information and overhead to guarantee data delivery.