Snowflake Storage Costs 101 - An In-Depth Guide (2024)
Snowflake has established itself as the industry leader in cloud-based data warehousing solutions, defined by its capacity to manage massive datasets while maintaining high scalability and query performance. This is accomplished via its distinct three-layer design (storage, computing, and cloud services). This format allows for easy data processing and analytics. What's more, Snowflake's unique storage format enables you to store data in an efficient and cost-effective manner. On average, Snowflake users spend more than half of their total budget on storage costs, thus optimizing Snowflake storage costs is crucial if you want to get the best ROI on your Snowflake investment.
In this article, we will cover everything you need to know about Snowflake storage costs and discuss ways for optimizing and lowering them. Whether you're a new or experienced Snowflake user, this article will explain how Snowflake storage costs are calculated and show you to specific areas where you may improve storage usage.
What Is Snowflake's Storage Layer All About?
Before we do a deep dive into the intricacies of understanding and optimizing Snowflake storage costs, let's first understand its architecture. Snowflake follows an architecture that separates storage, compute, and cloud services, known as the "multi-cluster, shared data" design. This architecture allows Snowflake to decouple these components while logically integrating them. It differs from traditional data warehouses, where storage, compute, and cloud services are tightly coupled. Let's dive into the design of a multi-cluster, shared data system, focusing on its three main components:
- Storage: Snowflake uses cloud storage services like AWS, Azure or Google Cloud for persistent data storage. This data isn't just dumped there though; Snowflake reorganizes it into a special format (optimized columnar format) that crams in more information while taking up less space. Snowflake takes care of everything behind the scenes, including data replication, scaling, and ensuring constant availability.
- Compute: Snowflake uses a cluster of independent virtual compute instances to execute queries and perform data processing tasks. These compute resources are provisioned and scaled automatically based on the workload.
- Cloud Services: Snowflake runs a set of cloud services responsible for various tasks, including infrastructure management, security, metadata management, query optimization, and workload management across the entire Snowflake environment.
This separation of storage, compute, and cloud services enables Snowflake to expand each component independently, resulting in great performance and effective resource utilization.
Save up to 30% on your Snowflake spend in a few minutes!
How Does Snowflake Charge for Storage?
Snowflake storage costs are an important factor to consider when using it. The monthly costs for storing data in Snowflake are based on a flat rate per terabyte (TB) of consumption (after being compressed). The amount charged will depend on the Cloud Platform and the region, whether US-, Asia-, or EU-based, wherever you are located, or your account type either Capacity or On demand (We will dive into this later on).
Note: Snowflake storage costs can vary depending on the type of data you are storing and the duration for which you keep it.
In Snowflake, storage costs are primarily determined by the amount of data stored and the storage region. There are several types of storage costs to consider:
Staged file storage cost in Snowflake: It refers to the costs associated with storing files for bulk data loading or unloading in Snowflake. In Snowflake, data loading and unloading are typically done by staging the data in a file format, such as CSV or JSON, before loading it into or unloading from the Snowflake database. When a file is staged, it calculates storage costs based on the size of the file. This means Snowflake's cost fluctuates based on the size of the data. Snowflake does not charge data ingress fees to bring data into your account but does charge for data egress.
Note: Data ingress fees are free of charge, however, utilizing Snowpipe or executing COPY or INSERT queries to load data will incur a compute cost.
Take a look at this guide on loading data in Snowflake.
Database storage cost in Snowflake: It refers to the costs associated with storing data in Snowflake's databases. It includes the data stored in the database tables and any historical data maintained for Time travel. So, how does time travel work in Snowflake? Time travel is a feature in Snowflake that allows users to query their data as it existed at a specific point in time. This feature is used to recover lost data, track changes in data over time, or for compliance and auditing purposes. Historical data stored for Time Travel is also included in the database costs. Snowflake automatically compresses all data stored in tables, which helps optimize Snowflake storage used for an account. The compressed file size is used to calculate the total storage used for an account, and this is used to determine the costs associated with the data stored in the databases. The compressed file size is smaller than the original file size, so the cost will eventually be lower.
Time Travel and Fail-safe Costs: These refer to the costs associated with maintaining historical data and ensuring data integrity in Snowflake. These costs are calculated per day based on the amount of data that is changed during that time period.
Time Travel Storage Costs in Snowflake:
- Snowflake’s Time Travel feature allows users to query their data as it existed at a specific point in time, and it also provides Snowflake query optimization and query cost reduction benefits.
- The number of days historical data is maintained is based on the table type and the Time Travel retention period for the table.
- Snowflake minimizes the amount of storage required for historical data by maintaining only the necessary information to restore the individual table rows that were updated or deleted.
Fail-safe Storage Costs in Snowflake:
- Snowflake’s Fail-safe features allows one to recover data even after the time travel period has ended. It is meant to be used in extreme cases, and it can only be accessed by Snowflake.
- The costs associated with Fail-safe are calculated based on the amount of data that is stored in multiple copies.
- Snowflake only maintains full copies of tables when tables are dropped or truncated.
Zero-copy cloning cost: It refers to the costs associated with creating a copy of a database, schema, or table along with its associated data in Snowflake without incurring any additional storage charges until changes are made to the cloned object. It is because zero-copy cloning is a metadata-only operation. For example, Snowflake storage costs charges will be applied at that point if a user clones a database and then adds a new table or deletes rows from a cloned table. Zero-copy cloning has many uses beyond creating backups, such as supporting the development and test environments.
Snowflake Storage Pricing Breakdown
Snowflake Service can be subscribed to on an On Demand basis, where usage is charged in advance every month, or on a Capacity basis, where a predetermined amount of usage is purchased up front. Pricing varies according to whether you are in On Demand or Capacity.
1) On Demand Snowflake storage costs on AWS
Here is the credit pricing breakdown of On-Demand Snowflake storage costs on AWS:
Cloud Provider | Region | Standard | Premier | Premier +1 | Premier +2 | Enterprise | Enterprise + Private Link | Business Critical | VPS |
---|---|---|---|---|---|---|---|---|---|
AWS | US East (Northern Virginia) | $2.00 | $2.25 | $2.50 | $2.75 | $3.00 | $3.30 | $4.00 | $6.00 |
AWS | US West (Oregon) | $2.00 | $2.25 | $2.50 | $2.75 | $3.00 | $3.30 | $4.00 | $6.00 |
AWS | EU Dublin | $2.60 | $2.95 | $3.25 | $3.60 | $3.90 | $4.30 | $5.20 | $7.80 |
AWS | EU Frankfurt | $2.60 | $2.95 | $3.25 | $3.60 | $3.90 | $4.30 | $5.20 | $7.80 |
AWS | AP Sydney | $2.75 | $3.05 | $3.45 | $3.75 | $4.05 | $4.50 | $5.50 | $8.25 |
AWS | AP Singapore | $2.50 | $2.80 | $3.10 | $3.40 | $3.70 | $4.05 | $5.00 | $7.50 |
AWS | Canada Central | $2.25 | $2.50 | $3.00 | $3.25 | $3.50 | $3.90 | $4.50 | $6.75 |
AWS | US East 2 (Ohio) | $2.00 | $2.25 | $2.50 | $2.75 | $3.00 | $3.30 | $4.00 | $6.00 |
AWS | AP Northeast 1 (Tokyo) | $2.85 | $3.20 | $3.45 | $3.75 | $4.30 | $4.70 | $5.70 | $8.55 |
AWS | AP Mumbai | $2.20 | $2.50 | $2.70 | $3.00 | $3.30 | $3.60 | $4.40 | $6.60 |
AWS | US East 1 Commercial Gov | - | - | - | - | - | - | $4.80 | $7.20 |
AWS | Europe (London) | $2.70 | $3.00 | $3.40 | $3.70 | $4.00 | $4.40 | $5.40 | $8.10 |
AWS | Asia Pacific (Seoul) | $2.75 | $3.05 | $3.45 | $3.75 | $4.05 | $4.50 | $5.50 | $8.25 |
AWS | US Gov West 1 | - | - | - | - | - | - | $5.60 | $8.40 |
AWS | US Gov West 1 (Fedramp High Plus) | - | - | - | - | - | - | $5.60 | $8.40 |
AWS | Europe (Stockholm) | $2.60 | $2.95 | $3.25 | $3.60 | $3.90 | $4.30 | $5.20 | $7.80 |
AWS | Asia Pacific (Osaka) | $2.85 | $3.20 | $3.45 | $3.75 | $4.30 | $4.70 | $5.70 | $8.55 |
AWS | South America East 1 (São Paulo) | $3.10 | $3.50 | $3.85 | $4.20 | $4.65 | $5.10 | $6.20 | $9.30 |
AWS | EU (Paris) | $2.60 | $2.95 | $3.25 | $3.60 | $3.90 | $4.30 | $5.20 | $7.80 |
AWS | Asia Pacific (Jakarta) | $2.50 | $2.80 | $3.10 | $3.40 | $3.70 | $4.05 | $5.00 | $7.50 |
AWS | US Gov East 1 (Fedramp High Plus) | - | - | - | - | - | - | $5.60 | $8.40 |
AWS | EU (Zurich) | $3.10 | $3.50 | $3.85 | $4.20 | $4.65 | $5.10 | $6.20 | $9.30 |
AWS | US Gov West 1 (DoD) | - | - | - | - | - | - | $5.60 | $8.40 |
2) On Demand Snowflake storage costs on Azure
Here is the credit pricing breakdown of On-Demand Snowflake storage costs on Azure:
Cloud Provider | Region | Standard | Premier | Premier +1 | Premier +2 | Enterprise | Enterprise + Private Link | Business Critical | VPS |
---|---|---|---|---|---|---|---|---|---|
Azure | East US 2 (Virginia) | $2.00 | $2.25 | $2.50 | $2.75 | $3.00 | $3.30 | $4.00 | $6.00 |
Azure | West US 2 (Washington) | $2.00 | $2.25 | $2.50 | $2.75 | $3.00 | $3.30 | $4.00 | $6.00 |
Azure | West Europe (Netherlands) | $2.60 | $2.95 | $3.25 | $3.60 | $3.90 | $4.30 | $5.20 | $7.80 |
Azure | Australia East (New South Wales) | $2.75 | $3.05 | $3.45 | $3.75 | $4.05 | $4.50 | $5.50 | $8.25 |
Azure | Canada Central (Toronto) | $2.25 | $2.50 | $3.00 | $3.25 | $3.50 | $3.90 | $4.50 | $6.75 |
Azure | Southeast Asia (Singapore) | $2.50 | $2.80 | $3.10 | $3.40 | $3.70 | $4.05 | $5.00 | $7.50 |
Azure | Switzerland North | $3.10 | $3.50 | $3.85 | $4.20 | $4.65 | $5.10 | $6.20 | $9.30 |
Azure | US Gov Virginia | - | - | - | - | - | - | $5.60 | $8.40 |
Azure | Central US (Iowa) | $2.00 | $2.25 | $2.50 | $2.75 | $3.00 | $3.30 | $4.00 | $6.00 |
Azure | North Europe (Ireland) | $2.60 | $2.95 | $3.25 | $3.60 | $3.90 | $4.30 | $5.20 | $7.80 |
Azure | Japan East (Tokyo) | $2.85 | $3.20 | $3.45 | $3.75 | $4.30 | $4.70 | $5.70 | $8.55 |
Azure | UAE North (Dubai) | $2.70 | $3.00 | $3.40 | $3.70 | $4.00 | $4.40 | $5.40 | $8.10 |
Azure | South Central US (Texas) | $2.00 | $2.25 | $2.50 | $2.75 | $3.00 | $3.30 | $4.00 | $6.00 |
Azure | Central India (Pune) | $2.20 | $2.50 | $2.70 | $3.00 | $3.30 | $3.60 | $4.40 | $6.60 |
Azure | UK South (London) | $2.70 | $3.00 | $3.40 | $3.70 | $4.00 | $4.40 | $5.40 | $8.10 |
3) On Demand Snowflake storage costs on GCP
Here is the credit pricing breakdown of On-Demand Snowflake storage costs on GCP:
Cloud Provider | Region | Standard | Premier | Premier +1 | Premier +2 | Enterprise | Enterprise + Private Link | Business Critical | VPS |
---|---|---|---|---|---|---|---|---|---|
GCP | US Central 1 (Iowa) | $2.00 | $2.25 | $2.50 | $2.75 | $3.00 | $3.30 | $4.00 | $6.00 |
GCP | US East 4 (N. Virginia) | $2.00 | $2.25 | $2.50 | $2.75 | $3.00 | $3.30 | $4.00 | $6.00 |
GCP | Europe West 4 (Netherlands) | $2.60 | $2.95 | $3.25 | $3.60 | $3.90 | $4.30 | $5.20 | $7.80 |
GCP | Europe West 2 (London) | $2.70 | $3.00 | $3.40 | $3.70 | $4.00 | $4.40 | $5.40 | $8.10 |
Now let’s look at how capacity pricing works on Snowflake storage.
Capacity pricing is calculated by applying the snowflake credit discount from your order form to the on demand credit price for the relevant cloud provider, region, and edition. Purchased capacity can be used to any of your accounts on the snowflake service.
1) Capacity Snowflake storage costs on AWS
Here is the credit pricing breakdown of Capacity Snowflake storage costs on AWS:
Cloud Provider | Region | On Demand Storage Pricing (TB/mo) | Tier 1 | Tier 2 | Tier 3 | Tier 4 | Tier 5 | Tier 6 | Tier 7 |
---|---|---|---|---|---|---|---|---|---|
AWS | US East (Northern Virginia) | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
AWS | US West (Oregon) | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
AWS | EU Dublin | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
AWS | EU Frankfurt | $24.50 | $24.50 | $22.87 | $21.24 | $19.60 | $17.96 | $16.34 | $14.70 |
AWS | AP Sydney | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
AWS | AP Singapore | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
AWS | Canada Central | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
AWS | US East 2 (Ohio) | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
AWS | AP Northeast 1 (Tokyo) | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
AWS | AP Mumbai | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
AWS | US East 1 Commercial Gov | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
AWS | Europe (London) | $24.00 | $24.00 | $22.40 | $20.81 | $19.20 | $17.59 | $16.01 | $14.40 |
AWS | Asia Pacific (Seoul) | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
AWS | US Gov West 1 | $39.00 | $39.00 | $36.40 | $33.81 | $31.20 | $28.59 | $26.01 | $23.40 |
AWS | US Gov West 1 (Fedramp High Plus) | $39.00 | $39.00 | $36.40 | $33.81 | $31.20 | $28.59 | $26.01 | $23.40 |
AWS | Europe (Stockholm) | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
AWS | Asia Pacific (Osaka) | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
AWS | South America East 1 (São Paulo) | $40.50 | $40.50 | $37.80 | $35.11 | $32.40 | $29.69 | $27.01 | $24.30 |
AWS | EU (Paris) | $24.00 | $24.00 | $22.40 | $20.81 | $19.20 | $17.59 | $16.01 | $14.40 |
AWS | Asia Pacific (Jakarta) | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
AWS | US Gov East 1 (Fedramp High Plus) | $39.00 | $39.00 | $36.40 | $33.81 | $31.20 | $28.59 | $26.01 | $23.40 |
AWS | EU (Zurich) | $26.95 | $26.95 | $25.15 | $23.37 | $21.56 | $19.75 | $17.98 | $16.17 |
AWS | US Gov West 1 (DoD)10 | $39.00 | $39.00 | $36.40 | $33.81 | $31.20 | $28.59 | $26.01 | $23.40 |
Tier 1 = USD $0 - $1,199,999
Tier 2 = USD $1,200,000 - $2,999,999
Tier 3 = USD $3,000,000 - $4,999,999
Tier 4 = USD $5,000,000 - $9,999,999
Tier 5 = USD $10,000,000 - $19,999,999
Tier 6 = USD $20,000,000 - $39,999,999
Tier 7 = USD $40,000,000+
2) Capacity Snowflake storage costs on Azure
Here is the credit pricing breakdown of Capacity Snowflake storage costs on Azure:
Cloud Provider | Region | On Demand Storage Pricing (TB/mo) | Tier 1 | Tier 2 | Tier 3 | Tier 4 | Tier 5 | Tier 6 | Tier 7 |
---|---|---|---|---|---|---|---|---|---|
Azure | East US 2 (Virginia) | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
Azure | West US 2 (Washington) | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
Azure | West Europe (Netherlands) | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
Azure | Australia East (New South Wales) | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
Azure | Canada Central (Toronto) | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
Azure | Southeast Asia (Singapore) | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
Azure | Switzerland North | $28.80 | $28.80 | $26.88 | $24.97 | $23.04 | $21.11 | $19.21 | $17.28 |
Azure | US Gov Virginia | $39.00 | $39.00 | $36.40 | $33.81 | $31.20 | $28.59 | $26.01 | $23.40 |
Azure | US Central (Iowa) | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
Azure | North Europe (Ireland) | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
Azure | Japan East (Tokyo) | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
Azure | UAE North (Dubai) | $25.40 | $25.40 | $23.71 | $22.02 | $20.32 | $18.62 | $16.94 | $15.24 |
Azure | South Central US (Texas) | $23.00 | $23.00 | $21.47 | $19.94 | $18.40 | $16.86 | $15.34 | $13.80 |
Azure | Central India (Pune) | $25.00 | $25.00 | $23.33 | $21.68 | $20.00 | $18.33 | $16.68 | $15.00 |
Azure | UK South (London) | $24.00 | $24.00 | $22.40 | $20.81 | $19.20 | $17.59 | $16.01 | $14.40 |
Tier 1 = USD $0 - $1,199,999
Tier 2 = USD $1,200,000 - $2,999,999
Tier 3 = USD $3,000,000 - $4,999,999
Tier 4 = USD $5,000,000 - $9,999,999
Tier 5 = USD $10,000,000 - $19,999,999
Tier 6 = USD $20,000,000 - $39,999,999
Tier 7 = USD $40,000,000+
3) Capacity Snowflake storage costs on GCP
Here is the credit pricing breakdown of Capacity Snowflake storage costs on GCP:
Cloud Provider | Region | On Demand Storage Pricing (TB/mo) | Tier 1 | Tier 2 | Tier 3 | Tier 4 | Tier 5 | Tier 6 | Tier 7 |
---|---|---|---|---|---|---|---|---|---|
GCP | US Central 1 (Iowa) | $20.00 | $20.00 | $20.00 | $20.00 | $20.00 | $20.00 | $20.00 | $20.00 |
GCP | US East 4 (N. Virginia) | $23.00 | $23.00 | $23.00 | $23.00 | $23.00 | $23.00 | $23.00 | $23.00 |
GCP | Europe West 4 (Netherlands) | $20.00 | $20.00 | $20.00 | $20.00 | $20.00 | $20.00 | $20.00 | $20.00 |
GCP | Europe West 2 (London) | $23.00 | $23.00 | $23.00 | $23.00 | $23.00 | $23.00 | $23.00 | $23.00 |
Tier 1 = USD $0 - $1,199,999
Tier 2 = USD $1,200,000 - $2,999,999
Tier 3 = USD $3,000,000 - $4,999,999
Tier 4 = USD $5,000,000 - $9,999,999
Tier 5 = USD $10,000,000 - $19,999,999
Tier 6 = USD $20,000,000 - $39,999,999
Tier 7 = USD $40,000,000+
For a more detailed pricing breakdown of Snowflake storage costs, see this Snowflake pricing table.
Watch this video for a basic understanding of Snowflake storage pricing.
How to Monitor Snowflake Storage Costs Using Snowsight?
Monitoring data storage is an important aspect of Snowflake cost reduction and ensuring that your data is stored efficiently. As an ACCOUNTADMIN, you have the ability to view data storage across your entire account as well as for individual tables.
Account-wide Storage:
- As an admin, you can use Snowsight or even the classic web interface to view data storage across your entire account. But for the sake of this article, we will be using Snowsight to do it.
- In Snowsight, navigate to Admin > Usage > Storage.
- This page displays the total average Snowflake data storage for your account and all databases, stages, and data in fail-safe.
Individual Table Storage:
- Any user with the appropriate privileges can view the data storage for individual tables.
- In the Classic Web UI or Snowsight, navigate to Databases > “db_name” > Tables.
- This will show the storage usage for each table in the selected database.
Note: Keep an eye on how much data storage you're using so you're aware of any unexpected changes. This will help you find and fix any problems that might be affecting the efficiency of your data storage and help you get the most out of your storage costs.
To gain insight into historical Snowflake storage costs, users can access the ACCOUNT_USAGE and ORGANIZATION_USAGE schemas. These schemas provide detailed information about storage costs, including the amount of data stored, the duration of time the data was stored, and the cost associated with storing the data.
Viewing Snowflake Storage History for Your Organization
As we have previously discussed, the total Snowflake storage cost is comprised of various costs associated with different types of storage, including staged file storage, database table storage, and fail-safe and time-travel storage. To better understand Snowflake’s storage costs for your organization, users with the ACCOUNTADMIN role can use Snowsight to view the amount of data stored in Snowflake.
To access this storage info, you must navigate to the Admin section and select Usage from the drop-down menu.
From there, select Storage from the Usage Type drop-down.
It is essential to select a virtual warehouse when using the dashboard to view cost and usage information from the shared snowflake database, as it consumes compute resources when retrieving this data, Snowflake recommends using an X-Small(Extra Small) warehouse for this purpose.
Filter by Tag
Usage dashboard in your organization allows you to filter storage usage by a specific tag/value combination. This feature is designed to enable you to attribute Snowflake costs to specific logical units within your organization. Using tags, you can easily identify and track the storage usage for different departments, projects, or any other logical units you have defined in your organization. This feature is similar to filtering credit consumption by tag, enabling you to track and attribute costs to specific units within your organization. In both cases, using tags allows for easy tracking and cost attribution, making it easy to understand and manage your organization's storage and credit usage.
View Snowflake Storage by Type or Object
The bar graph on the Usage dashboard of your organization allows you to filter Snowflake storage usage data either By type or By object.
Filtering By Type, you can view the size of storage for each Snowflake storage category, such as Database, Fail Safe, and Stage. Also, storage associated with Time Travel is included in the Database category, providing a comprehensive view of storage usage by type. This feature is useful for understanding the breakdown of storage usage across different storage categories and can help identify areas where Snowflake storage usage is particularly high or low.
Filtering By Object, displays the size of storage for each specific object. For example, you can view the size of a particular database or stage. This feature allows you to drill down and see the detailed storage usage for specific objects, which can be useful for identifying and addressing storage usage issues at the individual object level.
Viewing Data Usage for a Table in Snowflake
Snowsight allows users with the appropriate access privileges to view the size (in bytes) of individual tables within a schema or database. This feature is useful for understanding the storage usage of specific tables and can help identify and address storage usage issues at the table level.
To view the size of a table using Snowsight, follow these steps:
Step 1—Select Data > Databases from the main menu.
Step 2—On the left side of the Databases page, use the database object explorer to view the database and schema.
Step 3—Expand the database and any schema in the database to view the tables within it.
Step 4—Click on any table to view its statistics, including its size.
Query for Table Size in Snowflake
It is possible to gain insights into tables, including their size, by writing SQL queries, instead of using the Snowsight web interface because this allows users for more flexibility + automation when working with large amounts of data. A user with the proper access/privileges can list data about tables using the SHOW TABLES command.
For example, the following query will list all tables in a specific schema:
SHOW TABLES IN SCHEMA your_schema;
Let's go a bit further. So now that we know what the SHOW TABLES command does,it's time to dive deep into actually calculating the size of the individual table so users with the ACCOUNTADMIN role can use SQL to view table size information by executing queries against the TABLE_STORAGE_METRICS view in the ACCOUNT_USAGE schema. This view shows the table-level storage utilization info, which can be utilized to compute the storage billing for every table in the account, including those that have been removed but are still consuming the storage fees. TABLE_STORAGE_METRICS contains storage information about all tables that a particular account holds and tons of information about table size, including the number of bytes currently being stored, the number of bytes that have been stored historically—and more. For a quick example, here is a sample query that will calculate and return the total table size in GB for the table DATASETS which is present in REAL_ESTATE_DATA_ATLAS database:
USE role ACCOUNTADMIN;
SELECT TABLE_NAME,
TABLE_SCHEMA,
Sum(((active_bytes + time_travel_bytes + failsafe_bytes + retained_for_clone_bytes)/1024)/1024)/1024 AS TOTAL_STORAGE_USAGE_IN_GB
FROM REAL_ESTATE_DATA_ATLAS.INFORMATION_SCHEMA.TABLE_STORAGE_METRICS WHERE TABLE_NAME in ("DATASETS");
GROUP BY 1,2
ORDER BY 1,2,3
Note: To query the TABLE_STORAGE_METRICS view, the user must have ACCOUNTADMIN privilege and there might be 1-2 hour delay in updating the storage related stats for active_bytes + time_travel_bytes + failsafe_bytes + retained_for_clone_bytes in this view.
Query for Snowflake Storage Costs: ORGANIZATION_USAGE and ACCOUNT_USAGE Schemas
So before we even start to query the data for Snowflake storage cost, we need to understand that Snowflake provides two schemas that make it possible to query storage cost: ORGANIZATION_USAGE and ACCOUNT_USAGE. These schemas contain data related to usage and cost and provide very detailed and granular, analytics-ready usage data to build custom reports or even dashboards.
ORGANIZATION_USAGE schema contains data about usage and costs at the organization level, which includes data about storage usage and cost for all the databases and stages within an organization in a shared database named SNOWFLAKE. Only the users with the ORGADMIN or ACCOUNTADMIN role can access the ORGANIZATION_USAGE schema.
For more information on the ORGANIZATION_USAGE views, please refer to this.
ACCOUNT_USAGE schema contains data about usage and costs at the account level, which includes data about storage usage and cost for all the tables within an account.
For more information on the ACCOUNT_USAGE views, please refer to this.
Most views in these two schemas contain the cost of storage in terms of storage size. But, if you want to view the cost in currency instead of size, you can write queries using the USAGE_IN_CURRENCY_DAILY View. This view converts the storage size into actual currency using the daily price of a TB allowing users to easily understand the actual cost of storage in terms of currency.
SELECT
DATE_TRUNC('day', USAGE_DATE) AS "Usage Date",
SUM(USAGE) AS "Total Usage",
SUM(USAGE_IN_CURRENCY) AS "Total Cost"
FROM
ORGANIZATION_USAGE.USAGE_IN_CURRENCY_DAILY
WHERE
ORGANIZATION_NAME = 'YourOrganizationName'
AND USAGE_TYPE = 'YourUsageType'
AND USAGE_DATE BETWEEN 'start_date' AND 'end_date'
AND CURRENCY = 'CurrencyOfTheUsage'
GROUP BY
1
ORDER BY
1 DESC
LIMIT
10;
This particular query returns the total usage and total cost for a specific organization, usage type, and date range, grouped by day and ordered by decreasing usage date, with a limit of 10 rows.
Snowflake Storage Cost Reduction Techniques for Maximizing Snowflake ROI
Let's talk about some ways to keep Snowflake storage costs as low as possible. We've already talked about how storage, compute, and services are the three main things that make up Snowflake costs. Snowflake's pricing is based on how much you use it, so you only pay for what you use. It's really very important to keep an eye on certain areas to reduce storage costs, as you may be BURNING up space unnecessarily. Here are some important places to keep an eye on to find ways to clean up and cut down on storage costs.
- Staged files for bulk data loading and unloading consume storage space. Frequently check the STORAGE_USAGE view in ACCOUNT_USAGE, which might give an idea of how much space is consumed by stages.
- Unused Tables: Use Snowflake's ACCESS_HISTORY object to find how frequently the objects are queried and drop those that haven't been used in a certain period of time.
- Time travel Costs: Time travel is a unique feature of Snowflake that retains deleted or updated data for a specified number of days, but it is important to note that this stored history data encounters the same cost as active data. Hence, always be careful, make sure to check it, and consider the data criticality and table churn rate when setting up time-travel retention periods.
- Transient Tables: Consider having a transient database/schema for environments where data has low importance, such as staging environments. This will help control storage costs and avoid unnecessary data retention.
Check out this article to find out more in depth about techniques to reduce Snowflake costs.
Want to take Chaos Genius for a spin?
It takes less than 5 minutes.
Conclusion
And that's a wrap! It's crucial to keep a close eye on your Snowflake storage costs. You don't want to end up paying for resources you're not really using. Using the tips and tricks we covered in this article, you can keep those storage costs under control and get the most bang for your buck with Snowflake.
In this article, we've covered:
- Snowflake Architecture Breakdown
- What Is Snowflake's Storage Layer ?
- How Does Snowflake Charge for Storage?
- Snowflake Storage Pricing Breakdown
- On Demand Snowflake storage costs on AWS
- On Demand Snowflake storage costs on Azure
- On Demand Snowflake storage costs on GCP
- Capacity Snowflake storage costs on AWS
- Capacity Snowflake storage costs on Azure
- Capacity Snowflake storage costs on GCP
- How to Monitor Snowflake Storage Costs?
- Snowflake Storage Cost Reduction Techniques
... and so much more
FAQs
Does Snowflake charge for data storage?
Yes, Snowflake charges for data storage based on the amount of compressed data stored in its cloud storage layer.
How storage cost is calculated in Snowflake?
Snowflake storage cost is calculated based on the amount of compressed data stored, with a flat rate per terabyte. The rate varies depending on the cloud platform, region, and pricing model (On-Demand or Capacity). The total storage cost includes costs for database storage, staged file storage, Time Travel storage, Fail-safe storage, and zero-copy cloning.
What are the different types of storage costs in Snowflake?
The main storage costs include staged file storage, database storage, Time Travel storage, Fail-safe storage, and zero-copy cloning.
How much does Snowflake data storage cost?
The cost of Snowflake data storage varies depending on the cloud platform (AWS, Azure, or GCP), the region, and whether you're on an On-Demand or Capacity pricing model. The cost is a flat rate per terabyte of compressed data stored, with discounted rates available for higher storage tiers under Capacity pricing.
What is the difference between On-Demand and Capacity pricing for storage?
On-Demand pricing is charged monthly based on usage, while Capacity pricing involves purchasing a predetermined amount of usage upfront with discounted rates.
What is staged file storage cost in Snowflake?
Staged file storage cost refers to the cost associated with storing files for bulk data loading or unloading in Snowflake.
How can I monitor Snowflake storage costs?
Snowflake provides tools like Snowsight to monitor storage usage at the account-wide and individual table levels. Users can also query the ACCOUNT_USAGE and ORGANIZATION_USAGE schemas to gain detailed information about storage costs.
How much does Snowflake storage cost for 1 TB?
The cost of storing 1 TB of data in Snowflake varies based on factors such as account type, Cloud Platform, and region. For Capacity storage in the United States, it's around ~$23/month, while in the EU, it's approximately ~$24.50/month. With On Demand Pricing, it's ~$40/month in the US and ~$45/month in the EU.
What is the difference between the ACCOUNT_USAGE and ORGANIZATION_USAGE schemas?
ACCOUNT_USAGE contains data about usage and costs at the account level, while ORGANIZATION_USAGE contains data at the organization level.
How can you convert storage size into actual currency cost?
Use the USAGE_IN_CURRENCY_DAILY view to convert storage size into currency cost based on the daily price of a TB.
What is Snowflake's Time Travel feature, and how does it impact storage costs?
Time Travel retains deleted or updated data for a specified period, and the historical data incurs the same storage cost as active data.
How can you identify and remove unused tables to reduce storage costs?
Use Snowflake's ACCESS_HISTORY object to find infrequently queried tables and drop those that haven't been used in a certain period.
What is the difference between filtering storage usage "By Type" and "By Object" in Snowsight?
"By Type" shows storage usage for each category (Database, Fail Safe, Stage), while "By Object" shows usage for specific objects like databases or stages.
What is the purpose of the TABLE_STORAGE_METRICS view?
The TABLE_STORAGE_METRICS view shows detailed storage information for all tables in an account, including historical and failsafe data.
Which type of data incurs Snowflake storage costs?
Storage costs are incurred for all data stored in Snowflake databases, including data in tables, staged files for bulk loading/unloading, and historical data retained for Time Travel and Fail-safe features.
What is the storage capacity of Snowflake?
Snowflake does not have a fixed storage capacity limit. Its cloud-based architecture allows for virtually unlimited storage capacity, with the ability to scale up or down based on your usage and requirements.
What is the minimum cost of Snowflake?
Snowflake does not have a fixed minimum cost. The total cost depends on your usage of various Snowflake services, including storage, compute, and cloud services. The storage cost is based on the amount of data stored, with a flat rate per terabyte.
References
- https://docs.snowflake.com/en/user-guide/security-access-control-considerations.html#using-the-accountadmin-role
- https://docs.snowflake.com/en/user-guide/cost-exploring-data-storage.html#filter-by-tag
- https://alexandersks.medium.com/how-to-find-snowflake-table-size-2125880d07d7
- Snowflake: the Definitive Guide: Architecting, Designing, and Deploying on the Snowflake Data Cloud.
- https://docs.snowflake.com/en/user-guide/cost-understanding-overall.html#how-are-costs-incurred
- https://docs.snowflake.com/en/user-guide/cost-understanding-data-storage.html