The Analyze menu has been removed in Visual Studio 2026. The functionality provided by this menu has been moved into different places (i.e. Code Cleanup was moved into project context menus in Solution Explorer, etc).
To access Calculate code metrics, in Visual Studio 2026, simply click on View -> Other windows -> Code Metrics. In the tool window that opened, press this button:
. It will calculate code metrics for the selected/current project.
Note: There is no "for project/solution" option anymore. Instead, you have to select the individual project or solution via Solution Explorer whose code metrics will be calculated:
- In order to calculate code metrics for the entire solution, select the solution in Solution Explorer prior to calculating code metrics
- In order to calculate code metrics for a project, select the individual project in Solution Explorer prior to calculating code metrics
In addition, the Code Metrics tool no longer updates the results automatically (i.e. adding 3 lines of code doesn't update it). In order to update the result, press the same
button.