# How do I diagnose a slow Snowflake query with Query History and Query Profile?

Exam: COF-C03 — SnowPro Core Certification Exam
Knowledge domain: Performance Optimization, Querying, and Transformation
Updated: 2026-11-25T08:00:23.012467+00:00
HTML: https://learningpathx.com/faq/COF-C03/cofc03-snowflake-query-profile-slow-query-diagnosis.html

## Also asked as

- Which Query Profile metrics explain Snowflake query latency?
- How can I tell whether a Snowflake query is queued, blocked, scanning too much, or spilling?

Find the query ID in Snowsight Query History and inspect status and timings before opening Query Profile. Separate provisioning, overload queueing, transaction blocking, compilation, and execution. If execution dominates and a profile is visible, inspect the operators that account for the most time and follow their input and output rows.

* A table scan that reads many partitions for a narrow result suggests checking the predicate and data layout. Look at partitions scanned, bytes scanned, and where rows are filtered.
* A join that emits far more rows than its inputs suggests checking join keys and cardinality. An operator spilling large amounts to local or remote storage suggests reducing intermediate data or testing more warehouse memory. With Query Acceleration enabled, a small remote spill value can occur without a memory bottleneck.
* Use the time breakdown to distinguish processing, disk I/O, network transfer, synchronization, and initialization. A dominant network component can reflect movement within execution, so use the operator and history evidence before attributing it to the client connection.

A missing profile can reflect a query that is running, failed before execution, aged out, or is outside the role’s visibility. Profile detail is best effort. Preserve the query ID and available error or timing details, then use the same indicators after the change.

[Review query details and Query Profile](https://docs.snowflake.com/en/user-guide/ui-snowsight-activity) · [Query History timings and scan metrics](https://docs.snowflake.com/en/sql-reference/account-usage/query_history) · [Warehouse memory and spill](https://docs.snowflake.com/en/user-guide/performance-query-warehouse-memory)

Source: [Monitoring Queries, Warehouses, Storage, and Account Activity](https://learningpathx.com/news/monitoring-queries-warehouses-storage-and-account-activity.html)
