GKE Lens
GKE Lens allows you to measure your Google Kubernetes Engine (GKE) clusters cost against best practices and identify areas for improvement.
Required Permissions: Cloud Analytics
Access GKE Lens dashboard
The GKE Lens dashboard is automatically created when GKE-based workloads are detected in your Google Cloud projects.
To access the GKE Lens dashboard, select Dashboard from the top navigation bar, and then select GKE Lens.
To take full advantage of GKE Lens, you should have enabled GKE cost allocation on all the clusters you want to measure. See Understand GKE costs for more information.
Widgets
The GKE Lens dashboard contains widgets that highlight various aspects of your GKE spend.
Widgets on the GKE Lens dashboard are updated every 12 hours by default, independent of each other. See Refresh report data for more information.
Control Plane Cost
Shows the cost of the GKE control plane (also known as master node) across all clusters in the last 6 months.
Report configuration:
- Metric: Cost
- Aggregation: Total
- Time Interval: Month
- Time Range: Last 6 months
- Group by: SKU, Region
- Filters:
- Metric filter: Cost not between -US$0.01 AND US$0.01
- Service equals
Kubernetes Engine (GKE)
GKE Nodes Cost by Cluster
Shows GKE nodes cost in the last 30 days with forecast for the next 30 days.
Report configuration:
- Metric: Cost
- Aggregation: Total
- Advanced Analysis: Forecast
- Time Interval: Day
- Time Range: Last 30 days
- Group by: GKE Cluster
- Filters:
- GKE Cluster not equals
[GKE Cluster N/A]
: to exclude clusters not tracked by GKE cost allocation (see View GKE cluster costs). - Label
goog-gke-node
equals[Value N/A]
: to include Compute Engine VM instance underlying a GKE node (see Automatically applied labels).
- GKE Cluster not equals
Cost by Top 15 Namespaces
Shows the top 15 Kubernetes namespaces by cost across all clusters in the last 7 days.
Report configuration:
- Metric: Cost
- Aggregation: Total
- Time Interval: Day
- Time Range: Last 7 days
- Group by: GKE Namespace
- Filters:
- GKE Namespace not equals
[GKE Namespace N/A]
: to exclude namespaces not tracked by GKE cost allocation (see View GKE cluster costs). - Limit to top 15 GKE namespaces by cost
- GKE Namespace not equals
Cost by Top 20 Clusters
Shows the top 20 Kubernetes clusters by cost in the last 7 days.
Report configuration:
- Metric: Cost
- Aggregation: Total
- Time Interval: Day
- Time Range: Last 7 days
- Group by: GKE Cluster
- Filters:
- GKE Cluster not equals
[GKE Cluster N/A]
: to exclude clusters not tracked by GKE cost allocation. - Limit to top 20 GKE Clusters by cost
- GKE Cluster not equals
Unallocated Resources by Cluster
Shows the cost of resources that are neither requested by workloads nor requested for system overhead in the last 7 days.
Report configuration:
- Metric: Cost
- Aggregation: Total
- Time Interval: Day
- Time Range: Last 7 days
- Group by: GKE Cluster
- Filters:
- GKE Cluster not equals
[GKE Cluster N/A]
: to exclude clusters not tracked by GKE cost allocation. - GKE Namespace equals
kube:unallocated
: to include resources that are neither requested by workloads nor requested for system overhead.
- GKE Cluster not equals
GKE Clusters Utilization
Shows the utilization of resources across GKE clusters.
Report configuration:
- Metric: GKE Capacity Utilization
- Aggregation: Total
- Time Interval: Day
- Time Range: Last 7 days
- Group by: GKE Cluster
- Filters:
- Attribution is
GKE Unallocated Resources
orGKE Allocated Resources
- GKE Cluster not equals
[GKE Cluster N/A]
: to exclude clusters not tracked by GKE cost allocation.
- Attribution is
GKE Interactive Cost Explorer
A treemap that allows you to drill down from clusters to namespaces and apps.
Report configuration:
- Metric: Cost
- Aggregation: Total
- Time Interval: Day
- Time Range: Last 7 days
- Group by:
- Filters:
- GKE Cluster not equals
[GKE Cluster N/A]
: to exclude clusters not tracked by GKE cost allocation. - GKE Namespace not equals
[GKE Namespace N/A]
: to exclude namespaces not tracked by GKE cost allocation.
- GKE Cluster not equals
FAQ
How much does GKE Lens cost?
GKE Lens itself doesn't incur extra cost.
Note that several report widgets of GKE Lens rely on GKE cost allocation. While DoiT does not charge extra for GKE cost allocation, enabling GKE cost allocation can increase your storage costs in BigQuery. See Potential data volume increase.