
BigQuery Cost & Performance Optimization
Guides an agent to cut BigQuery costs via editions, storage billing, partitioning, lifecycle rules and SQL tuning.
- Repository
- google/skills
- Stars
- 21,782
- Licence
- Apache-2.0
- Files
- 10 files
What it does
Once installed, the agent follows structured workflows for optimizing a Google BigQuery environment. It can help decide whether to move workloads from on-demand pricing to Editions and size reservations, choose physical vs. logical storage billing, design partitioning and clustering with ready-made DDL templates, set table and dataset expiration rules, evaluate search indexes, materialized views and BI Engine, and suggest SQL query improvements. It points users to Google's built-in recommendation tools and gives step-by-step guidance for them.
Great for
- Data engineers trying to reduce a BigQuery bill
- Platform teams rightsizing BigQuery reservations or planning an Editions migration
- Analysts who want their large tables and slow dashboards made cheaper and faster to query
Skip it if
- Diagnosing why one specific job failed or ran slowly, which the skill explicitly sends to bigquery-troubleshooting (risk: wrong tool for the job)
- Changing production schemas, billing models or expirations without review, since the skill generates DDL that modifies tables and can drop data via expiration settings
- Non-BigQuery warehouses, because all guidance is specific to Google Cloud BigQuery
Try asking
- “Should our project move from on-demand to BigQuery Editions? Help me size the reservation.”
- “Find unpartitioned tables in my dataset and write a CTAS migration to partition them by date.”
- “Compare physical and logical storage billing for my datasets and recommend one.”
- “Rewrite this slow SQL query to scan less data and reduce slot time.”
Install in 3 steps
- 1
Download the skill
The ZIP contains the 10 original files, the Apache-2.0 licence and an attribution note.
bigquery-optimization.zip - 2
Add it to your agent
Claude Code (all projects)
mkdir -p ~/.claude/skills && unzip bigquery-optimization.zip -d ~/.claude/skills/Claude Code / Agent SDK (this project only)
mkdir -p .claude/skills && unzip bigquery-optimization.zip -d .claude/skills/Claude apps (web/desktop): Settings → Capabilities → Skills → Upload skill, and choose the ZIP.
- 3
Ask for the task
No special command needed — the agent reads the skill's description and loads it when your request matches. Try one of the prompts above.
Get better results
- Review every generated DDL statement and run evaluation queries in a test project before applying changes to production.
- Give the agent your project ID and region up front, since storage queries must be scoped to the correct regional dataset and 0 rows can mean a region mismatch.
- Use the least-privileged IAM role that fits the task, and avoid placing service account keys in shared environments.
What's inside
- references/attribution.md
- references/bi_engine.md
- references/capacity_planning_editions.md
- references/materialized_views.md
- references/search_indexes.md
- references/sql_optimization.md
- references/storage_billing_models.md
- references/storage_lifecycle_management.md
- references/table_partitioning_clustering.md
- SKILL.md
Redistributed unmodified from google/skills under the Apache-2.0 licence. The assessment was drafted with AI from the skill's files on 2026-10-29. Skills can instruct your agent to run code — read SKILL.md and any scripts before installing.