Echo Protocol
A simple TCP or UDP service that sends received data back to its sender.
Postel, J., "Echo Protocol", STD 20, RFC 862, DOI 10.17487/RFC0862, May 1983, <https://www.rfc-editor.org/info/rfc862>.
@misc{rfc862,
series = {Request for Comments},
number = 862,
howpublished = {RFC 862},
publisher = {RFC Editor},
doi = {10.17487/RFC0862},
url = {https://www.rfc-editor.org/info/rfc862},
author = {J. Postel},
title = {{Echo Protocol}},
pagetotal = 1,
year = 1983,
month = may,
} RFC text
Network Working Group J. Postel
Request for Comments: 862 ISI
May 1983
Echo Protocol
This RFC specifies a standard for the ARPA Internet community. Hosts on
the ARPA Internet that choose to implement an Echo Protocol are expected
to adopt and implement this standard.
A very useful debugging and measurement tool is an echo service. An
echo service simply sends back to the originating source any data it
receives.
TCP Based Echo Service
One echo service is defined as a connection based application on TCP.
A server listens for TCP connections on TCP port 7. Once a
connection is established any data received is sent back. This
continues until the calling user terminates the connection.
UDP Based Echo Service
Another echo service is defined as a datagram based application on
UDP. A server listens for UDP datagrams on UDP port 7. When a
datagram is received, the data from it is sent back in an answering
datagram.
ISO Plain Language
On this page
§1A Basic Test Service
An echo service sends back any data it receives. The RFC describes it as a useful tool for debugging and measurement.
Hosts that choose to implement the protocol are expected to follow the behavior described in this memo.
The service returns the data sent to it. This makes it a simple way to check a network connection.
§2Echo over TCP and UDP
For TCP, a server listens on TCP port 7. After a connection is established, it sends back any data received and continues until the user ends the connection.
For UDP, a server listens on UDP port 7. For each datagram it receives, it sends the same data back in an answering datagram.
With TCP, the server returns data over the open connection until the user ends it. With UDP, each message sent to the server gets a matching message back.
§3The Echoed Data
The service returns the received data to its source. The RFC does not describe additional processing or require a particular message format.
The server sends back the data it received, without changing the service into a more complex exchange.