Drupal is a registered trademark of Dries Buytaert
drupal 11.3.7 Update released for Drupal core (11.3.7)! drupal 11.2.11 Update released for Drupal core (11.2.11)! drupal 10.6.7 Update released for Drupal core (10.6.7)! drupal 10.5.9 Update released for Drupal core (10.5.9)! cms 2.1.1 Update released for Drupal core (2.1.1)! drupal 11.3.6 Update released for Drupal core (11.3.6)! drupal 10.6.6 Update released for Drupal core (10.6.6)! cms 2.1.0 Update released for Drupal core (2.1.0)! bootstrap 8.x-3.40 Minor update available for theme bootstrap (8.x-3.40). menu_link_attributes 8.x-1.7 Minor update available for module menu_link_attributes (8.x-1.7). eca 3.1.1 Minor update available for module eca (3.1.1). layout_paragraphs 2.1.3 Minor update available for module layout_paragraphs (2.1.3). ai 1.3.3 Minor update available for module ai (1.3.3). ai 1.2.14 Minor update available for module ai (1.2.14). node_revision_delete 2.0.3 Minor update available for module node_revision_delete (2.0.3). moderated_content_bulk_publish 2.0.52 Minor update available for module moderated_content_bulk_publish (2.0.52). klaro 3.0.10 Minor update available for module klaro (3.0.10). klaro 3.0.9 Minor update available for module klaro (3.0.9). layout_paragraphs 2.1.2 Minor update available for module layout_paragraphs (2.1.2). geofield_map 11.1.8 Minor update available for module geofield_map (11.1.8).

smart_trim

57,633 sites Security covered
View on drupal.org

Smart Trim implements a new field formatter for textfields (text, text_long, and text_with_summary) that improves upon the "Summary or Trimmed" formatter built into Drupal core.

Requirements

Drupal contrib modules

Installation

Install and enable Smart Trim as you would any other contributed module. See
https://www.drupal.org/docs/extending-drupal/installing-modules

Configuration

After installing and enabling Smart Trim, you will see a "Smart trimmed" option in the format dropdown for your text fields. For content types, this is located on the "Manage Display" page. With Smart Trim, you have control over:

  • The trim length
  • Whether the trim length is measured in characters or words
  • Appending an optional suffix at the trim point
  • Configuring (optional) "More" link immediately after the trimmed text
  • Stripping out HTML tags from the field
  • Ability to customize the trimmed content via template override

The "More" link functionality may not make sense in many contexts, and may be redundant in situations where "Read More" is included in set of links included with the node. But it's there if you need it.

As Smart Trim provides a field formatter, use it anywhere field formatters are available, including Layout Builder and Views.

Mission statement

Smart Trim is designed to be a focused, lightweight improvement over Drupal core's current formatter trimming capabilities. The maintainers' focus is stability and ease-of-use. Customizations to the module are encouraged with template overrides and Smart Trim hook implementations.

Documentation

Getting started (example)

  1. Navigate to Administration > Extend and enable the module.
  2. Navigate to Administration > Structure > Content types > Article > Manage display, then click to configure the "Teaser" view mode.
    (/admin/structure/types/manage/article/display/teaser)
  3. Select Smart trimmed as the Format for the Body field.
  4. Click the configuration gear for the Body field.
  5. Update Smart Trim formatter configuration as desired. Configuration options include:
    • Trim by number of characters or words.
    • Customize the "More" link.

As Smart Trim provides a field formatter, use it anywhere field formatters are available, including Layout Builder and Views.

Full documentation

https://www.drupal.org/docs/contributed-modules/smart-trim

Maintenance plan

The latest release is actively maintained for the latest versions of Drupal (Drupal 10+)

Activity

Total releases
2
First release
Jan 2026
Latest release
3 months ago
Release cadence
0 days
Stability
100% stable

Releases

Version Type Release date
2.3.1 Stable Jan 11, 2026
2.3.0 Stable Jan 11, 2026