Skip to main content
Drupal is a registered trademark of Dries Buytaert
Release: OpenID Connect / OAuth client 3.0.0-alpha9 New alpha version released for module openid_connect (3.0.0-alpha9). Usage Milestone: Google Analytics Module google_analytics crossed 1,000 active installs. Release: Timelinr 1.0.1 Minor update available for module timelinr (1.0.1). Release: GraphQL Compose Codegen 1.1.2 Minor update available for module graphql_compose_codegen (1.1.2). Release: Mapy.com 1.1.3 Minor update available for module mapycom (1.1.3). Release: Ckeditor5 entity browser 3.0.3 Minor update available for module ckeditor5_entity_browser (3.0.3). Release: Ckeditor5 entity browser 3.0.1 Minor update available for module ckeditor5_entity_browser (3.0.1). Release: Ckeditor5 entity browser 3.0.2 Minor update available for module ckeditor5_entity_browser (3.0.2). Release: Teamleader Integration 4.0.2 Minor update available for module teamleader (4.0.2). Module Revived: Entityqueue Buttons 1.1.2 Module entityqueue_buttons updated after 8 months of inactivity (1.1.2).

Menu Link View Count

23 sites No security coverage
View on drupal.org

This module allows you to display dynamic counts on menu links, showing the number of results from a chosen Views display. This is useful for indicating things like unread messages or pending items directly in your navigation.

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.

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
4
Tracked since
Jan 2026
Latest release
6 months ago
Releases (12 mo)
4 ▲ from 0
Maintenance
Slowing

Release Timeline

Releases

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