0
0
GcpComparisonBeginner · 3 min read

Standard vs Nearline vs Coldline vs Archive in GCP: Key Differences

In GCP, Standard storage is for frequently accessed data, Nearline is for data accessed less than once a month, Coldline suits data accessed less than once a quarter, and Archive is for rarely accessed data, like backups, accessed less than once a year. Costs decrease from Standard to Archive, but access times and retrieval fees increase.
⚖️

Quick Comparison

This table summarizes the main differences between GCP storage classes.

Storage ClassAccess FrequencyStorage Cost (per GB/month)Retrieval CostMinimum Storage DurationUse Case
StandardFrequent (multiple times per month)HighestNoneNoneActive data, websites, apps
NearlineLess than once a monthLower than StandardModerate30 daysBackup, data accessed monthly
ColdlineLess than once every 3 monthsLower than NearlineHigher90 daysDisaster recovery, archival
ArchiveLess than once a yearLowestHighest365 daysLong-term archival, compliance
⚖️

Key Differences

Standard storage is designed for data you need often and quickly, like website files or active databases. It has the highest storage cost but no extra fees for accessing data.

Nearline is cheaper for storage but charges a fee when you retrieve data. It suits backups or data you check monthly. It requires you to keep data for at least 30 days to avoid extra charges.

Coldline lowers storage costs further but increases retrieval fees and minimum storage duration to 90 days. It is ideal for disaster recovery or data you rarely need but want to keep accessible.

Archive offers the lowest storage cost but the highest retrieval cost and slowest access times, with a minimum 365-day storage. Use it for data you almost never access but must keep long-term, like compliance records.

⚖️

Code Comparison

Here is how to create a Standard storage bucket using the gcloud command-line tool.

bash
gcloud storage buckets create my-standard-bucket --location=us --storage-class=STANDARD
Output
Created bucket [my-standard-bucket].
↔️

Nearline Equivalent

To create a Nearline storage bucket, change the storage class in the command.

bash
gcloud storage buckets create my-nearline-bucket --location=us --storage-class=NEARLINE
Output
Created bucket [my-nearline-bucket].
🎯

When to Use Which

Choose Standard when you need fast, frequent access to your data, like for websites or apps.

Choose Nearline for data you access less than once a month, such as monthly backups.

Choose Coldline for data accessed rarely, like quarterly disaster recovery copies.

Choose Archive for long-term storage of data you almost never access but must keep, like compliance archives.

Key Takeaways

Standard storage is best for frequent, fast access with no retrieval fees.
Nearline and Coldline reduce storage costs but add retrieval fees and minimum storage times.
Archive offers the lowest cost for rarely accessed data with highest retrieval cost and delay.
Pick storage class based on how often you access data and how long you plan to keep it.
Use gcloud commands to create buckets with the desired storage class easily.