Before you set a cap, find the noisy logs
Your application looks healthy, but your Log Analytics bill shows otherwise. Before setting the daily cap, find out what you are actually collecting, and why.
The problem
You set up a new environment. You connect Application Insights, enable diagnostic settings on your resources, and send everything to a central Log Analytics workspace. It follows the docs, it works, and the visibility is great.
A few weeks later, log ingestion starts showing up on the Azure bill. The first reaction is often: “Let’s set a daily cap.”
But a better question is: “What are we collecting, and how does it help us?”
Let’s focus on how Log Analytics charges you, why default “collect everything” setups grow fast, and why the daily cap is not the fix you think it is.
How it works
Log Analytics stores data in tables: AppTraces, ContainerLogV2, AzureDiagnostics, resource-specific tables, and so on. The main cost driver is billable ingestion volume, meaning how many GB land in those tables. Retention beyond the included period, the table plan, and some query operations add to it.
Each table has a plan:
- Analytics: full KQL, alerts, dashboards. This is the default and the most expensive to ingest.
- Basic: cheaper ingestion and limited querying. You pay per query, and only simple log alerts are supported.
- Auxiliary: lowest cost, for verbose low-touch data. It does not support alerts.
One thing that’s often missed: shortening retention does not reduce ingestion cost. Keeping data for fewer days does not undo the charge for ingesting it in the first place.
What causes the problem
The trap isn’t logging. The trap is collecting broadly during setup and never reviewing the result:
- every diagnostic category enabled “just in case”;
- debug or verbose logging left on after an incident;
- chatty container stdout nobody ever queries;
- several apps sharing one workspace, so no one sees which source is growing.
None of these is automatically wrong. Defaults favour visibility over cost, which is a reasonable starting point. The problem is never checking the resulting volume against its operational value.
Why the daily cap doesn’t fix it
- It is not precise. Ingestion can overshoot the cap, and the excess is still billed.
- When reached, it stops collection for Analytics and Basic tables until the daily reset. That means missing data for troubleshooting and log-based alerts.
- An Application Insights cap does not protect the rest of the workspace. Other resources sending logs to the same workspace keep ingesting. For workspace-based Application Insights, the lower of the two caps applies to the app’s data.
- Microsoft explicitly says the daily cap should not be your primary cost-reduction method.
The approach: measure, reduce, verify, then protect
-
① Measure: find the biggest contributors
Open the workspace, go to Insights → Usage, and check which tables dominate. Or run this query, from Microsoft’s usage analysis guidance, to see billable GB per table per day over the last month:
Usage | where TimeGenerated > ago(32d) | where StartTime >= startofday(ago(31d)) and EndTime < startofday(now()) | where IsBillable == true | summarize BillableDataGB = sum(Quantity) / 1000. by bin(StartTime, 1d), DataType | render columnchartThen check the top few tables. Which resources, clusters, namespaces or apps feed them? Did the volume jump after a deployment or a monitoring change?
-
② Reduce: remove noise before ingestion
- At the source: enable only the diagnostic categories you actually use, set sensible application log levels, and use sampling for suitable application telemetry.
- Before ingestion: use data collection rule (DCR) transformations to filter rows or drop columns, for supported tables and collection paths.
- Right plan: move verbose, rarely queried tables to Basic or Auxiliary if you don’t need full KQL or alerting on them.
Keep audit, security and incident-response data you are required to retain. Check transformation pricing and limitations too: not every filtered byte is automatically free.
-
③ Verify: make sure visibility still works
Compare daily ingestion across comparable workload periods. Test the alerts, dashboards and on-call queries that depend on the changed tables. Less data is not a success if your team loses a critical signal.
-
④ Protect: add safeguards
- If it fits your monitoring requirements, set a workspace daily cap under Usage and estimated costs as an emergency brake, set above normal daily volume.
- Create an alert so you know when the cap is reached, ideally with a billable-volume alert that fires before it.
- Review both caps for workspace-based Application Insights.
- Add Cost Management budget notifications. Remember that budgets only notify, cost data arrives with a delay, and they never stop ingestion.
A daily cap is an emergency brake, not a logging strategy.
Find the noisy source first. Keep the signals you actually need.