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).

menu_link_view_count

22 sites No security coverage
View on drupal.org

Allows site builders to add dynamic count indicators to menu links using Views. Configure each menu item to display the current result count from a selected View display.

Common use cases:

  • Unread messages (12)
  • Pending approvals (3)
  • My tasks (7)
  • Any menu link that should reflect a Views-driven “queue” or “inbox” style count

Installation/Configuration

1. Enable the module.
2. Add/edit a menu link
3. In the "View count" section select the View and display you want counted. Optionally set count limit (to cap at 99+, for example).
4. Save the menu link.
5. The menu will render the link title with an appended count indicator.

Views Setup

Be advised that some pagers do not provide the full count of rows from the view, which will also apply to the count that appears in the menu link.

For the pager, use either:

  • If you're planning to use a "count limit" on the menu item, use Display a specified number of items configured to limit to a value higher than the "count limit" expected to be on the menu item.
  • If you're not planning to use a "count limit" on the menu item, use Display all items. For performance considerations, it's recommended to keep this View as "basic" (as few columns, etc.) as possible.

Performance

Menu items with a count applied to them are subject to caching per the View's cache handling. This can cause frequent invalidation of the caching for menus and regions where you're displaying the menus based on the configuration of the view's caching.

One module to consider to mitigate possible performance concerns is Views Custom Cache Tags.

Customization

To customize styling, override CSS in your theme targeting:

  • ul.menu li.has-count > a
  • ul.menu li.has-count > a .count

To customize markup/behavior, hook_menu_link_view_count_alter() in a custom module (or theme) to adjust rendering, classes, count math, or cache/attachments.

Additional Requirements

Views (Drupal core) is required.

Activity

Total releases
4
First release
Jan 2026
Latest release
1 month ago
Release cadence
17 days
Stability
0% stable

Release Timeline

Releases

Version Type Release date
1.0.0-beta3 Pre-release Feb 24, 2026
1.0.0-beta2 Pre-release Jan 4, 2026
1.0.0-beta1 Pre-release Jan 4, 2026
1.0.x-dev Dev Jan 3, 2026