To reduce AWS Glue and Athena costs, make every query scan less data. Amazon Athena bills $5 per terabyte scanned, so converting data to Apache Parquet, partitioning by the columns you filter on, and compressing files can cut a query's cost by an order of magnitude with no change to the SQL. AWS Glue bills $0.44 per DPU-hour for standard ETL, so right-size worker type and DPU count, use Flex execution at $0.29 per DPU-hour for non-urgent batch, and enable job bookmarks to process only new data. Scan less and compute less: both bills fall together.
Last updated: June 2026 · Written by Fredrik Filipsson and reviewed by Morten Andersen · See, Cut, Lock, Run method
Amazon Athena is AWS's serverless query service that runs SQL directly against data in Amazon S3, and AWS Glue is the managed ETL and data-catalog service that prepares that data. Together they are the backbone of many data lakes, and together they are easy to overspend on, because Athena charges by the byte scanned and Glue charges by the compute-hour, and both quietly scale with sloppy data layout. This guide is part of our complete guide to AWS cost optimization, the cluster pillar it links up to.
What drives AWS Glue and Athena costs?
Athena cost is driven by bytes scanned and Glue cost by DPU-hours, so both reward doing less work over the same data. Athena bills $5 per terabyte scanned, with a 10 MB minimum per query, per the Amazon Athena pricing page; DDL statements are free, and the bill is set entirely by how much data each query reads. Glue bills $0.44 per DPU-hour for ETL jobs and interactive sessions, with a lower Flex rate of $0.29 per DPU-hour for non-urgent batch, per the AWS Glue pricing page; one DPU is roughly 4 vCPUs and 16 GB of memory, and you pay for the DPUs a job holds for as long as it runs. Verify both rates for your Region before modeling, since pricing varies by Region and changes over time.
How do I lower Athena query costs step by step?
Lower Athena costs by shrinking the data each query has to read, through format, partitioning, compression, and tighter SQL. Work through these steps:
- Convert data to a columnar format. Store query data as Apache Parquet or ORC so Athena reads only the columns a query references instead of every row. For analytics queries that touch a few columns of wide tables, this alone often cuts bytes scanned by most of the total.
- Partition the data. Partition tables by the columns queries filter on, typically date, region, or tenant, so Athena prunes irrelevant partitions and scans only matching data. A query for one day against a year of data should read one day, not the year.
- Compress files and right-size them. Compress with Snappy or zstd, and aim for files of roughly 128 MB to 1 GB. Compression reduces bytes scanned directly, and right-sized files avoid the overhead of many tiny objects.
- Select only the columns you need. Replace
SELECT *with explicit columns and add selective filters, so even a well-laid-out table is read narrowly. Every column and partition you avoid is bytes you do not pay to scan. - Cache and reuse results. Use Athena query result reuse for repeated identical queries, and materialize common aggregations so dashboards do not rescan raw data on every refresh.
The columnar and partitioning work is covered in depth, with file-layout specifics, in our companion guide to the data-cost cluster, how to optimize Parquet and columnar storage for query cost. The streaming source that often feeds these tables is covered in the sibling guide how to cut Amazon Kinesis and Data Streams costs.
A CSV forces Athena to read every byte of every row. Parquet stores data by column and keeps per-column statistics, so a query that touches three columns of a fifty-column table reads roughly three columns of data, not fifty. Format is usually the single biggest Athena saving available.
How do I reduce AWS Glue job costs?
Reduce Glue costs by right-sizing the compute each job holds and by processing only the data that changed. Match the worker type to the job: lighter workers for modest transforms, larger ones only where the job genuinely needs the memory, and tune DPU count to avoid over-allocating parallelism a job cannot use. Use Glue Flex execution at $0.29 per DPU-hour for non-urgent batch jobs that can tolerate variable start times, a roughly 34 percent saving over standard. Enable job bookmarks so a recurring job processes only new or changed data rather than reprocessing the whole dataset every run, which cuts both Glue DPU-hours and the downstream Athena scans on the output. Keep the Glue Data Catalog tidy too: the first million objects per month are free, so prune stale tables and partitions. This is the same waste-elimination discipline behind our AWS cost optimization service.
Data lake bill climbing faster than the data?
Our AWS cost audit profiles your heaviest Athena queries and Glue jobs, fixes the data layout, right-sizes the compute, and proves the scan-and-DPU savings before anything is committed. On the performance model, you pay only from realized savings. No savings, no fee.
Book a cloud cost audit →Should I use Athena provisioned capacity or pay per query?
Use pay-per-query for variable, exploratory workloads and provisioned capacity for steady, high-volume query traffic where you want predictable cost and isolation. Pay-per-query at $5 per terabyte scanned is simplest and cheapest for intermittent analytics, because you pay only for the data each query reads. Athena provisioned capacity, billed per DPU-hour for capacity you reserve, suits teams running large, sustained query volumes that want a fixed cost ceiling and workload isolation rather than per-query billing. For most organizations the bigger lever is still scanning less data; provisioned capacity is a billing-model choice you make after the data layout is already efficient, not a substitute for fixing it. Model both against your actual query history before switching.
The AWS Cost Optimization Field Guide includes the data-lake checklist we run across Athena, Glue, and S3, so the scan and compute savings hold after the first pass.
Frequently asked questions
How much does Amazon Athena cost per query?
Athena bills $5 per terabyte of data scanned, with a 10 MB minimum per query, so a query that scans 100 GB costs about $0.50. DDL statements are free. The cost depends entirely on bytes read, which is why columnar format, partitioning, and compression are the main levers.
Does converting to Parquet really cut Athena costs?
Yes, usually dramatically. Parquet stores data by column with per-column statistics, so a query reading a few columns of a wide table scans a fraction of what a row-based CSV would force it to read. Format conversion is often the single largest Athena saving available and requires no change to the SQL.
What is AWS Glue Flex execution?
Flex execution runs Glue jobs on spare capacity at $0.29 per DPU-hour instead of the standard $0.44, a saving of about 34 percent. It suits non-urgent batch jobs that can tolerate variable start and run times, such as nightly ETL, and is not meant for latency-sensitive pipelines.
How do job bookmarks lower Glue costs?
Job bookmarks track which data a Glue job has already processed, so a recurring job reads only new or changed records instead of reprocessing the entire dataset each run. That cuts Glue DPU-hours directly and shrinks the output that downstream Athena queries then scan.
The short version
Athena and Glue both reward doing less work over the same data. Convert to Parquet, partition by your filter columns, compress, and select only what you need, and Athena scans a fraction of the bytes at $5 per terabyte. Right-size Glue workers, use Flex at $0.29 per DPU-hour for non-urgent batch, and enable bookmarks so jobs touch only new data. Scan less and compute less, and both bills fall. When you want your data lake profiled and proven down, that is the work our AWS cost optimization service delivers.
Cloud pricing and service behavior change frequently. Verify the specifics in this guide against the providers’ own current documentation and the FinOps Foundation: AWS pricing ↗, AWS documentation ↗ and FinOps Foundation Framework ↗. This article also reflects Cloud Cost Room’s hands-on, vendor-neutral engagement experience.