On this page
Installing and Configuring Maxlength
Drupal 7 will no longer be supported after January 5, 2025. Learn more and find resources for Drupal 7 sites
Installation
Install the Maxlength module using the standard installation method for contributed modules.
Once installed, be sure to enable the module.
Configuration
Once Maxlength is installed and enabled, assign the module-provided Bypass maxlength setting permission to the intended user roles. Note that this will hide the character count text from fields for user roles with that permission.
Next enable Maxlength for the intended fields. You can apply a maximum length to the following field types:
- Text (formatted)
- Text (formatted, long)
- Text (formatted, long, with summary)
- Text (plain)
- Text (plain, long)
Navigate to the Manage fields page of the intended entity. For example, Structure > Content Types > Article > Manage fields (/admin/structure/types/manage/article/fields)
Click the edit link next to the field you want to set a maximum length to.
Maxlength provides the following configuration options:
- The maximum number of characters allowed
- The countdown message, including tokens for character limit, characters remaining, and characters used.
- Force text truncate
- Truncate HTML
WYSIWYG Compatibility
Help improve this page
You can:
- Log in, click Edit, and edit this page
- Log in, click Discuss, update the Page status value, and suggest an improvement
- Log in and create a Documentation issue with your suggestion

