How long can an alt attribute be?
The HTML specification does not define a maximum length for “alt” attributes. However, their intended function is to provide short, efficient alternate text so that users who cannot see an image can access the content presented in the image. Browsers’ and certain assistive technologies’ current method of rendering “alt” attributes reinforces the need to keep them short.