A server is a storage on which contents of web pages, e-mails or files are stored. Every program or app needs servers in the background to store and process its users’ data, including WhatsApp, for example.
When sending messages, it then works like this: When person A sends a message, the first thing that happens is that it is sent to WhatsApp’s servers. They ensure that the exchange of messages works. This is comparable to a post office, where all letters are collected before they are delivered. The message is then forwarded to person B from the WhatsApp servers. Afterwards, person B can read the message on his smartphone. Compared to letter mail, the exchange happens online in just a few seconds.