- All
- Engineering
- Operating Systems
Powered by AI and the LinkedIn community
1
What is TCP?
2
What is UDP?
3
Advantages of TCP over UDP
4
Disadvantages of TCP over UDP
5
When to use TCP or UDP
6
Here’s what else to consider
TCP and UDP are two of the most common protocols for sending and receiving data over a network. They both have their own advantages and disadvantages, depending on the type of application and the network conditions. In this article, you will learn what are the advantages of using TCP over UDP in OS networking and communication, and when you might prefer one over the other.
Key takeaways from this article
-
Reliable data delivery:
TCP ensures every packet of data sent reaches its destination correctly and in sequence. This is like sending a series of numbered letters and getting a confirmation for each one received—it's methodical and meticulous.
-
Acknowledgment mechanism:
TCP waits for a thumbs-up from the receiver before sending the next data packet. Imagine texting a friend and waiting for their 'Got it!' before sending the next message—ensures nothing gets missed.
This summary is powered by AI and these experts
- Lucianderson Gomes Network Administrator | Network…
1 What is TCP?
TCP stands for Transmission Control Protocol, and it is a reliable, connection-oriented, and stream-based protocol. This means that TCP establishes a connection between two endpoints before sending any data, and ensures that the data is delivered in the same order and without any errors or losses. TCP also adapts to the network congestion and adjusts the data transmission rate accordingly. TCP is ideal for applications that require high reliability, such as web browsing, email, file transfer, and remote access.
Help others by sharing more (125 characters min.)
- Suhas Marathe 🌟 38 Years Sculpting Business Excellence | 🚀 Powering Triumph with Sangam CRM: 2000+ Users, 80+ Call Center Locations | Tele-calling and Lead Management Solution | #SangamCRM
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
TCP is preferred over UDP for its reliability and error-checking mechanisms. Unlike UDP, TCP ensures the delivery of data by establishing a connection, managing packet acknowledgment, and retransmitting lost packets. This reliability makes TCP ideal for applications where accurate and complete data transmission is crucial, such as file transfers, web browsing, and email communication.In contrast, UDP is connectionless and does not guarantee the delivery of every packet. While this makes UDP faster and more suitable for real-time applications like online gaming and video streaming, it may result in occasional data loss.
LikeLike
Celebrate
Support
Love
Insightful
Funny
15
- Luciano Omena Health IT Professional | RIS/PACS/LIS Specialist
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
TCP, or Transmission Control Protocol, is a fundamental piece of the Internet architecture. Operating at the transport layer, TCP is a connection-oriented protocol, ensuring reliability in data transmission between devices. Before exchanging data, TCP establishes a connection, ensuring not only accurate delivery but also the correct order of data. Its adaptability to network congestion, dynamically adjusting the transmission rate, contributes to efficiency in digital communication. In short, TCP is essential for applications that demand reliability, such as web browsing, email, and file transfer, playing a crucial role in global interconnection.
LikeLike
Celebrate
Support
Love
Insightful
Funny
4
- Sripad Muthigi Customer Success Evangelist | Data Operations Champion | Revenue Growth Strategist
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
In data transmission, TCP and UDP, integral to the operating system, have distinct roles. TCP ensures reliable delivery, vital for secure connections and web browsing. It establishes a secure connection, managed by the operating system, before data transfer. UDP prioritizes speed, key for real-time applications like online gaming, with occasional data loss deemed acceptable. Operating systems oversee these protocols, orchestrating the delicate balance between reliability, speed, and tolerance for data loss, crucial in determining the apt choice between TCP and UDP for specific applications.
LikeLike
Celebrate
Support
Love
Insightful
Funny
4
- Deepak Sharma Solution Architect - Network and Hybrid Cloud Infrastructure
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
Every protocol has its own advantage and disadvantage, it entirely depends upon use case and scenarios.Most of the applications cannot afford to lose any packet... Hence use of TCP protocol to have reliable and guaranteed connection is required.However in some cases UDP make sense, more than reliability one can take advantage of low latency by some applications like DNS, NTP etc.....
LikeLike
Celebrate
Support
Love
Insightful
Funny
4
- Andrew Grant Manager: Systems Infrastructure, UniSA
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
UDP is data delivered like water from a fire hose. Unrestrained.TCP is like data delivered, verified and rate controlled via an (amazing) courier in teeny tiny packages.
LikeLike
Celebrate
Support
Love
Insightful
Funny
4
Load more contributions
2 What is UDP?
UDP stands for User Datagram Protocol, and it is an unreliable, connectionless, and message-based protocol. This means that UDP does not establish a connection or guarantee the delivery of the data. UDP simply sends the data as individual messages, or datagrams, without checking for errors or losses. UDP also does not adapt to the network congestion and does not control the data transmission rate. UDP is ideal for applications that require low latency, high speed, or real-time performance, such as video streaming, voice over IP, online gaming, and broadcasting.
Help others by sharing more (125 characters min.)
- Bruno Feliciano Network Administrator
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
É um protocolo de comunicação que não garante a entrega confiável de dados entre dois hosts em uma rede de computadores.Ele é usado por uma ampla variedade de aplicações que exigem eficiência, velocidade ou sensibilidade ao tempo.
Translated
LikeLike
Celebrate
Support
Love
Insightful
Funny
8
- Danish Sethi IT Manager at FAIRDEAL AUTOMOBILES PRIVATE LIMITED
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
The User Datagram Protocol, or UDP, is a communication protocol used across the Internet for especially time-sensitive transmissions such as video playback or DNS lookups. It speeds up communications by not formally establishing a connection before data is transferred.
LikeLike
Celebrate
Support
Love
See AlsoWhy Netflix use TCP instead of UDP?DNS works on both TCP and UDP - Windows ServerTCP vs UDP ProtocolsHow Applications Coexist Over TCP and UDP? - GeeksforGeeksInsightful
Funny
2
- Chris Masuku / Information Technology Consultant IT Technology Support Consultant
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
One of the advantages of using TCP over UDP is that TCP provides reliable and error-checked data transfer, while UDP does not. TCP ensures that all data sent by one device is received by another in the correct order and without any loss or corruption. UDP, on the other hand, does not guarantee the delivery, order, or integrity of the data. UDP is faster and simpler than TCP, but it is not suitable for situations where data loss is unacceptable
LikeLike
Celebrate
Support
Love
Insightful
Funny
2
- Diego Gonzalez Analista de Segurança da Informação | Threat Intelligence | 12 x Microsoft | Comptia Security + | ITILV4 |
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
O UDP é um protocolo sem conexão isso significa que, ao contrário do TCP, o UDP não estabelece uma conexão antes de enviar dados e não garante a entrega ordenada e confiável dos pacotes.
Translated
LikeLike
Celebrate
Support
Love
Insightful
Funny
2
- Diego S Silva Analista de Redes | Infraestrutura
(edited)
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
O UDP, é perfeito para entrega de Streaming por exemplo, chamada de voz, consultas rápidas, etc. Não é orientado a conexão, isto é, não se importa se os pacotes foram recebidos, ou não pelo destinatário. Também não se preocupa com a reordenação dos pacotes como faz o TCP, tornando -o mais eficiente em streaming, jogos online, ligação, etc.
Translated
LikeLike
Celebrate
Support
Love
Insightful
Funny
1
Load more contributions
3 Advantages of TCP over UDP
One of the main advantages of using TCP over UDP is that TCP provides reliability and data integrity. TCP ensures that the data is delivered correctly and in the right order, and that any lost or corrupted packets are retransmitted. TCP also handles the flow control and congestion control, which prevent the sender from overwhelming the receiver or the network. TCP can also handle variable-length data streams, while UDP can only handle fixed-size messages.
Another advantage of using TCP over UDP is that TCP simplifies the application development and debugging. TCP handles the low-level details of the data transmission, such as establishing and terminating the connection, segmenting and reassembling the data, and acknowledging and retransmitting the packets. This allows the application to focus on the high-level logic and functionality, without worrying about the network issues. TCP also provides a consistent and predictable interface for the application, while UDP may vary depending on the network conditions and the implementation.
Help others by sharing more (125 characters min.)
- Steve Mays OSC Sr Business Analyst
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
TCP has ack handshakes that verify packet delivery.UDP doesn't acknowledge packet delivery and doesn't care if it's made it.
LikeLike
Celebrate
Support
Love
Insightful
Funny
6
- Afzan iZAD Sable Disaster Recovery Coordinator | Disaster Recovery Plan
(edited)
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
TCP and UDP are both protocols used for sending and receiving data over networks. TCP (Transmission Control Protocol) is like a reliable blood vessel, ensuring that all data packets are delivered in the correct order and without loss. UDP (User Datagram Protocol), on the other hand, is like a faster blood vessel that doesn't guarantee delivery or order, but allows for quicker transmission.
LikeLike
Celebrate
Support
Love
Insightful
Funny
6
- Thiago C. Senior Cloud Platform Engineer at Fueled⛽️ | Sr. DevOps | 8x Microsoft Azure Certified | Kubernetes Certified (CKA)
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
TCP, the dependable one, offers a few advantages over its chill buddy UDP:1. Reliability: TCP is like a careful planner. It makes sure each piece of data reaches its destination correctly.2. Order Matters: TCP keeps things in line. It ensures data arrives in the same order it was sent.3. Checks and Balances: TCP is the meticulous type. It double-checks to ensure all data is received, resending anything missing.So, while TCP might be slower than UDP, it's your go-to for ensuring everything arrives just right, like a trusted mail service!
LikeLike
Celebrate
Support
Love
Insightful
Funny
4
- Ahmed AlaaEldin Cloud Operations Engineer @ _VOIS | Cloud Administration, Microsoft 365
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
Imagine two friends each one of them on a side, person A sends a message to a person B, person A will wait till person B tells him that I received your message, please send the next message.
LikeLike
Celebrate
Support
Love
Insightful
Funny
3
-
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
Most powerful advantage of TCP over UDP is its security.Another advantage of using TCP over UDP is that TCP simplifies the application development and debugging. TCP handles the low-level details of the data transmission, such as establishing and terminating the connection, segmenting and reassembling the data, and acknowledging and retransmitting the packets. This allows the application to focus on the high-level logic and functionality, without worrying about the network issues.
LikeLike
Celebrate
Support
Love
Insightful
Funny
3
Load more contributions
4 Disadvantages of TCP over UDP
One of the main disadvantages of using TCP over UDP is that TCP introduces overhead and latency. TCP requires more packets and more processing to establish and maintain the connection, to acknowledge and retransmit the packets, and to adjust the transmission rate. TCP also imposes a fixed order and sequence on the data, which may not be necessary or desirable for some applications. TCP may also cause delays or jitter in the data delivery, which may affect the quality and performance of the application.
Another disadvantage of using TCP over UDP is that TCP may not be suitable for some applications and scenarios. TCP may not be able to handle high-volume or bursty data, such as multimedia or real-time data, which may require more bandwidth or more flexibility than TCP can offer. TCP may also not be able to cope with unreliable or dynamic networks, such as wireless or mobile networks, which may cause frequent packet losses or connection failures. TCP may also not be compatible with some network devices or protocols, such as routers, firewalls, or NAT, which may interfere with the TCP connection or packets.
Help others by sharing more (125 characters min.)
- Fernando Lanner Cardoso
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
UDP is ideal for internet chat, video streaming, and VOIP, where timely delivery is more critical than perfect accuracy. While UDP may cause some buffering in your video feed, it's generally less than what TCP would produce due to its lower overhead. This is because UDP, unlike TCP, doesn't require acknowledgement for each packet, allowing for continuous streaming even in fluctuating network conditions. This makes UDP a preferred choice for applications where even a slight delay can affect the user experience, like live video or audio chats.
LikeLike
Celebrate
Support
Love
Insightful
Funny
7
- Rami Fayoumi IT Audit | IT Risk Management | Information Security | CISA | MBA
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
TCP's is primarily intended for unicast communication, on the other hand UDP offers native support for multicast, which allows for easy data transmission to multiple recipients simultaneously. Unlike TCP, this eventually makes UDP more suitable for applications like video conferencing and online gaming, where data needs to be distributed to multiple users at the same time.
LikeLike
Celebrate
Support
Love
Insightful
Funny
6
- Ibaa Oueichek, PhD
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
One specific disadvantage of TCP over UDP is the higher latency due to the need to establish a connection before exchanging data between both sides. The latency and delay induced by TCP, in addition to higher bandwidth usage due to acknowledgements and retransmission of packets are a tradeoff to the reliability and ease of programming offered by TCP.
LikeLike
Celebrate
Support
Love
Insightful
Funny
4
- Ahmed AlaaEldin Cloud Operations Engineer @ _VOIS | Cloud Administration, Microsoft 365
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
There is nothing called disadvantage or advantage over a protocol than another because every protocol has its own purpose and use. When you need a connection that requires data integrity and to ensure for not losing a single network packet, you can with TCP.When you need high speed connection and protocol must complete the connection regardless of the losing packets.
LikeLike
Celebrate
Support
Love
Insightful
Funny
3
- Phumlani Ngobese Senior Server Engineer at University of Venda
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
Overhead: TCP has more overhead in terms of packet size and the number of control messages exchanged between sender and receiver, which can impact network performance, especially for short, simple transactions.Slower speed: Due to the additional features such as error checking, flow control, and retransmissions, TCP can be slower than UDP, particularly in situations where speed is crucial, such as real-time applications or online gaming.Connection-oriented: TCP requires the establishment of a connection before data transfer.Unsuitability for certain applications: Some applications, such as real-time streaming or voice over IP, may not require the level of reliability and sequencing provided by TCP
LikeLike
Celebrate
Support
Love
Insightful
Funny
3
Load more contributions
5 When to use TCP or UDP
The choice of using TCP or UDP depends on the requirements and characteristics of the application and the network. Generally, TCP is preferred for applications that need reliability, data integrity, and consistency, while UDP is preferred for applications that need speed, efficiency, and flexibility. However, there may be trade-offs and exceptions depending on the specific situation and context. For instance, web browsing, email, file transfer, remote access, and database access are typically done using TCP. On the other hand, video streaming, Voice over IP, online gaming, broadcasting, and DNS are usually done using UDP.
Help others by sharing more (125 characters min.)
- Ibaa Oueichek, PhD
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
The choice of TCP or UDP is totally dependent on the type of the application and it priorities. If speed and low response time are the most important then UDP is preferred, but then the application would have to provide its own solution to the problem of lost or corrupted data. If the application is going to run over a LAN, which is usually associated with very low error rate, then UDP also could have a clear edge as the reliability offered by TCP would not really relevant.
LikeLike
Celebrate
Support
Love
Insightful
Funny
6
- Camilo Osorio Capacho VoIP Engineer | DCAA | Nice Incontact | Asterisk | Avaya
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
TCP: Para aplicaciones que requieren confiabilidad en la entrega, como transferencia de archivos, navegación web y correo electrónico.UDP: Para aplicaciones sensibles al tiempo y tolerantes a la pérdida de datos, como transmisión de video, juegos en línea y voz sobre IP.
Translated
LikeLike
Celebrate
Support
Love
Insightful
Funny
5
- Carlos Nkuba Ph.D. in Computer Science and Engineering || Visiting Scholar || Postdoctoral Researcher at CSSA, Korea University || Consulting Network Engineer || Frm. President at decoc-elites.org
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
Making a choice between TCP and UDP really depends on the specific requirements of the application in need.TCP is preferred when reliability and ordered data delivery are crucial such as file transfers and email communication. In contrast, UDP is chosen for real-time applications that aim to prioritize low latency, making it suitable for online gaming and streaming despite the occasional data loss.Owing to the quality and features of TCP, it is paramount for connection-dependent services such as remote desktop access or secure financial transactions which require a stable, trusted and secure initial setup connection. Nonetheless, UDP is preferred in service and applications where tolerable data loss is acceptable, i.e., VoIP, streaming.
LikeLike
Celebrate
Support
Love
Insightful
Funny
5
- Danish Sethi IT Manager at FAIRDEAL AUTOMOBILES PRIVATE LIMITED
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
UDP is commonly used in time-sensitive communications where occasionally dropping packets is better than waiting. Voice and video traffic are often sent using this protocol because they are both time-sensitive and designed to handle some level of loss.TCP/IP can be used to provide remote login over the network for interactive file transfer to deliver email, to deliver webpages over the network and to remotely access a server host's file system.
LikeLike
Celebrate
Support
Love
Insightful
Funny
1
-
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
There will be least data leakage in TCP compared to UDP,.. UDP is made for. Spontaneous connection and to transfer smaller and simple files.. TCP is for secure, streamlined, strict transfers so it takes few more seconds to make connections
LikeLike
Celebrate
Support
Love
Insightful
Funny
1
Load more contributions
6 Here’s what else to consider
This is a space to share examples, stories, or insights that don’t fit into any of the previous sections. What else would you like to add?
Help others by sharing more (125 characters min.)
- Lucianderson Gomes Network Administrator | Network Security | SC-900 | CAPC
(edited)
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
O conhecimento de todos os protocolos das camadas do Modelo TCP/IP e o funcionamento de cada camada é fundamental para quem trabalha com informática, principalmente quem trabalha com redes de computadores, eles são a base para ser um bom profissional.
Translated
LikeLike
Celebrate
Support
Love
Insightful
Funny
1
- Abhishek Singh
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
TCP is used by almost everyone. It’s the main protocol powering the Internet. It allows applications to be built without worrying about how to deliver packets from point A to point B. The packets are reordered in sequence before delivering to applications and reliability is achieved using retransmissions.The only reason to not use it is when retransmissions are useless. When late data is as bad as no data - as can be the case for voice and video. These applications prefer self correction to retransmission and timeliness is paramount. Another case is heartbeats which is by nature retransmitted. So there is no big impact of losing a packet/beat. Since it is a short message there is no need to reorder things either.
LikeLike
Celebrate
Support
Love
Insightful
Funny
15
- Venky Raju, CISSP while (True) { learn(); make(); hack(); teach(); lead() }
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
I can’t believe no one has already mentioned the UDP joke. I could tell you but you probably won’t get it!On a more serious note, while UDP is best effort, it is the underpinning of QUIC, a transport protocol that has addressed long standing issues with TCP.And HTTP/3 uses QUIC as the transport layer.
LikeLike
Celebrate
Support
Love
Insightful
Funny
6
- Sri Hari Raj R Software Engineer
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
There will be least data leakage in TCP compared to UDP,.. UDP is made for. Spontaneous connection and to transfer smaller and simple files.. TCP is for secure, streamlined, strict transfers so it takes few more seconds to make connections
LikeLike
Celebrate
Support
Love
Insightful
Funny
2
- Katie D. I work tech to sing karaoke | DevOps Engineer | Mama Bear 🏳️⚧️🏳️🌈
- Report contribution
Thanks for letting us know! You'll no longer see this contribution
That these articles glom onto a bunch of jargon while ignoring history.Look at an old movie with an operator at a plug board. That's circuit switched communication.Now imagine sending messages as post cards or classified ads. That's packet switched networking (unicast and broadcast).TCP emulates circuit switched communication on a packet switched network.And your designs depend on whether someone through it should emulate a teletype attached to a computer (TCP)... or a deck of punched cards (UDP). Most engineers only imagined a dumb terminal and here we are optimized for that.
LikeLike
Celebrate
Support
Love
Insightful
Funny
2
Load more contributions
Operating Systems
Operating Systems
+ Follow
Rate this article
We created this article with the help of AI. What do you think of it?
It’s great It’s not so great
Thanks for your feedback
Your feedback is private. Like or react to bring the conversation to your network.
Tell us more
Tell us why you didn’t like this article.
If you think something in this article goes against our Professional Community Policies, please let us know.
We appreciate you letting us know. Though we’re unable to respond directly, your feedback helps us improve this experience for everyone.
If you think this goes against our Professional Community Policies, please let us know.
More articles on Operating Systems
No more previous content
- Your IT team has varied OS upgrade preferences. How will you align everyone for smooth transitions?
- Here's how you can advance your career in Operating Systems through delegation.
- You're dealing with tight project deadlines and compatibility issues. How do you decide what to prioritize?
- Your sensitive data is at risk due to an outdated operating system. How can you safeguard it effectively?
- You're facing critical updates for essential operating systems. How can you ensure minimal downtime?
No more next content
Explore Other Skills
- Programming
- Web Development
- Machine Learning
- Software Development
- Computer Science
- Data Engineering
- Data Analytics
- Data Science
- Artificial Intelligence (AI)
- Cloud Computing
More relevant reading
- Computer Hardware What distinguishes TCP from UDP in computer networking?
- Computer Networking What is the purpose of prefix sets in BGP and IPv6 route filtering?
- Computer Networking How has the OSPF protocol evolved?
- Electronic Engineering How can you improve electronic system scalability with communication and networking protocols?