Limit the number of characters

Is it possible for me to limit the number of characters sent by the user in the text input option?