Cost data in AWS cost explorer and Cost and Usage Report [CUR] doesn't match

0

In AWS I'm generating Cost and Usage Report [CUR] from the billing console with hourly granularity into S3 bucket and from there using cloud formation stack created a database in Athena but this data of different AWS services which I get by querying it doesn't match with the cost explorer data. I have already checked with the time standard and the region both CUR and cost explorer are same. Any help?

3 Answers
0

Hi - quite often any data discrepancy between CUR and Cost Explorer comes down to constructing the query in CUR and filters in Cost Explorer to match. As a test, I suggest you run a simple query in CUR to get total of unblended costs for the month of September, and to get the same from Cost Explorer. Use this CUR query (be sure to substitute your correct table name for the CUR report from September: select sum(line_item_unblended_cost) from <table_name_for_september>

Then in Cost Explorer, make sure the following filters are applied: Date Range: 2023-09-01 — 2023-09-30; Group By dimension: none; Charge Type: no filter; Advanced options/Aggregate Costs by: Unblended costs

The values from the CUR report and Cost Explorer should match if the parameters are the same.

AWS
answered 6 months ago
  • I tried this, the overall cost for the month of September matches but when I try to get the cost for specific services for a month the data doesn't match.

    For instance, I tried getting the data for S3 using this query: SELECT DATE_TRUNC('MONTH', line_item_usage_start_date) AS month, ROUND(SUM(line_item_unblended_cost),2) AS total_cost FROM cloudcost WHERE product_product_name = 'Amazon Simple Storage Service' AND month='9' GROUP BY DATE_TRUNC('MONTH', line_item_usage_start_date) ORDER BY month; From Athena I got $479.25 whereas in cost explorer it is $442.43. Removing rounding off also doesn't change the cost in CUR.

0

Given that the total costs match for September, it would seem that CUR and Cost Explorer data does in fact match, even though when you filter for S3 it seems a bit off. What I would suggest next is to check the total with just 'Usage' charge type to see if that number matches. This number would be excluding any discounts, refunds, credits, etc. To test: In Cost Explorer, select 'Usage' in the Charge Type filter, and modify your CUR query like this and see if the usage totals match: SELECT DATE_TRUNC('MONTH', line_item_usage_start_date) AS month, ROUND(SUM(line_item_unblended_cost),2) AS total_cost FROM cloudcost WHERE product_product_name = 'Amazon Simple Storage Service' AND month='9' and line_item_line_item_type = 'Usage' GROUP BY DATE_TRUNC('MONTH', line_item_usage_start_date) ORDER BY month;

AWS
answered 6 months ago
0

Be aware if you are using a Re-Seller your CUR data may not reflect your actual costs. If that is the Case Billing Conductor possibly maybe a solution for you.

answered 2 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions