Question: what is the minimum size of a udp datagram?
Answer: 8 bytes

Source port number This field identifies the sender 's port when meaningful and should be assumed to be the port to reply to if needed . If not used , then it should be zero . If the source host is the client , the port number is likely to be an ephemeral port number . If the source host is the server , the port number is likely to be a well - known port number . Destination port number This field identifies the receiver 's port and is required . Similar to source port number , if the client is the destination host then the port number will likely be an ephemeral port number and if the destination host is the server then the port number will likely be a well - known port number . Length A field that specifies the length in bytes of the UDP header and UDP data . The minimum length is 8 bytes because that is the length of the header . The field size sets a theoretical limit of 65,535 bytes ( 8 byte header + 65,527 bytes of data ) for a UDP datagram . However the actual limit for the data length , which is imposed by the underlying IPv4 protocol , is 65,507 bytes ( 65,535 - 8 byte UDP header - 20 byte IP header ) . In IPv6 jumbograms it is possible to have UDP packets of size greater than 65,535 bytes . RFC 2675 specifies that the length field is set to zero if the length of the UDP header plus UDP data is greater than 65,535 . Checksum The checksum field may be used for error - checking of the header and data . This field is optional in IPv4 , and mandatory in IPv6 . The field carries all - zeros if unused .