Host software MUST handle host names of up to 63 characters and SHOULD handle host names of up to 255 characters.
The DNS defines domain name syntax very generally -- a string of labels each containing up to 63 8-bit octets, separated by dots, and with a maximum total of 255 octets.
[1] https://www.freesoft.org/CIE/RFC/1035/9.htm