Understanding Drupal’s Routes and Menu System
Drupal’s routing and menu systems form the backbone of how requests are handled and navigation is built across sites. In the ninth instalment of his “Behind the Drops” series, Hari Venu explains how these pieces work together to define capability, control access, and generate user-facing links.
Hari describes routes as the source of truth, defined in .routing.yml files with paths, controllers, and permissions. Menus typically reference route names rather than controllers, allowing Drupal to resolve URLs at runtime while applying access checks, language handling, and path aliases. This approach keeps navigation stable even when underlying paths change.
The post also outlines how Drupal builds menus from multiple sources, including static YAML definitions, UI-created menu entities, and dynamic derivatives. Hari highlights dynamic routing and menu generation as key features that support scalable, data-driven navigation, reinforcing the core pattern: routes define capabilities, menus expose them, and link generation connects the two.

