Beginner’s Guide: TCP vs. UDP VPN

Data transferring illustration

When it comes to transferring data via VPN, the speed and reliability of the transfer depend primarily on the protocol that you use.

There are two that you can choose from – Transmission Control Protocol (TCP) and User Datagram Protocol (UDP).

If you've used any good VPN app from providers such as ExpressVPN, CyberGhost or NordVPN as well as many others you'll find both options in the settings area.

In essence, both of them are doing the same thing, allowing you to transfer data. However, they do it in different ways, which means that it matters which one you use.

Basically, one of them is faster, and the other is more reliable.

So, depending on what you need, speed or reliability, it's best to know which one to use, and what the differences between them are.

So, let's start from the beginning and we'll work through it step-by-step, so you have a better understanding allowing you to choose to correct option for your needs.

What are TCP and UDP and how do they work?

As mentioned, TCP and UDP are network protocols that you can use from transferring data online.

The data flows from your device to a server you are connected to. That means that you are using one of these protocols for every online action you take, be that watching online videos, listening to music, chatting to friends, reading articles (yes, you're using one right now), or anything else.

TCP UDP explainer

As for how these protocols work, we mentioned that they do pretty much the same thing.

They split your data into data packets, which are smaller units that are easier to send and receive.

Top Tip

Data Packets are like cutting a huge cake into more manageable pieces and sending them one by one in smaller boxes.

These packets include various technical details, such as different configurations, your IP address, the server's IP address, the data that you are sending, and the information that signals that the packet has ended, is called the trailer.

However, the difference lies in how they move this data.

How TCP moves data

TCP is the most commonly used protocol, and it is usually considered more reliable. When we send data online, more often than not, we are concerned with reliability, rather than with speed.

So, as mentioned, TCP splits data into packets, and each of the packets gets a piece of data known as the identifier.

Alongside that, it gets a sequence number that allows the receiving device to identify the packets. That way, it knows which came first, which is coming second, allowing it to be repackaged into one whole piece, kind of like putting the parts of a jigsaw puzzle back together.

Once the packet arrives at its destination, a signal is sent to the sender, which notifies it of the successful transfer.

Top Tip

The ‘Successful Transfer' is one of the major features that sets TCP apart from UDP.

After that, the next packet follows, and the process gets repeated. If the receiver doesn't send the acknowledging signal, the sender sends the same packet once again, assuming that the first one got lost.

That way, errors are easier to locate and fix, and the files arrive steadily and in the correct order.

In the end, the chances of the data arriving in full are much higher. But, the downside is that it takes a long time due to all of this communication.

NordVPN says “Because the data is sent in sequence, it helps with data congestion and flow control, and makes it easier to spot and fix any errors” (Source).

How UDP moves data

On the other hand, we have UDP, which is much faster, but also less reliable.

Where TCP sends data packet by packet, with communication confirming the arrival of each previous packet before the next one is sent, UDP sends packets in a stream.

Packets are moving one after another, but with no delay waiting for the all received answer, which makes things quicker. Still, it also makes it impossible to detect and fix potential errors or packets that went missing along the way.

Top Tip

UDP is like sending an item through the postal system without taking a signature of delivery at the end.

In other words, if one of the packets in the stream somehow gets lost, it simply will not arrive, and the sender will never know that it needs to send it again.

The receiver will still send acknowledgement, although only once the data transfer is completed in total, instead of confirming each segment.

Which protocol to use?

As mentioned, both of these protocols are VPN-compatible, which means that you can use any of them, depending on your preference.

They both work well with OpenVPN, which has grown to become a default VPN protocol for most providers.

ExpressVPN app settings screen

ExpressVPN allows you to choose between the two when using OpenVPN.

That way, the privacy and security of your data is guaranteed. As for which one to choose, as mentioned, that depends on your reason for using a VPN in the first place.

Of course, the reliability of TCP might mean that using this protocol is always the best option.

ProtonVPN points out that “TCP may allow you to use your VPN even if you are in a country that blocks VPNs”. (Source)

However, that is not necessarily the case. UDP is great for tasks that require fast data transfers, such as streaming, online gaming, and even VoIP services.

If you have an unreliable internet connection, then TCP is far superior although you will take a speed loss.

So ultimately it comes down to ‘speed' or ‘reliability'.

However, don't worry too much as on most modern devices and fast internet connections while you will see a speed difference when testing speeds you're often unlikely to notice that physically.

Conclusion

In the end, choosing between the two protocols depends on your plans.

For regular, casual browsing, any of them will likely do the trick. For sensitive actions, where you need your files delivered in their entirety, go for TCP.

On the other hand, if you need your files to travel quickly such as torrenting or streaming, and you can afford to lose a packet or two along the way, UDP is the way to go.

Illustrations © Mast3r & Vaeenma | Dreamstime.com

Ali Raza

Author: Ali Raza

Ali is a journalist with a keen interest in VPN usage. He is an expert in the field and has been covering VPN related topics for VPNCompare and numerous well-respected publications for many years.

Leave a Reply

Your email address will not be published. Required fields are marked *

Sign up to our newsletter

Get the latest privacy news, expert VPN guides & TV unblocking how-to’s sent straight to your inbox.