As described in How billing works, each of Neon's plans includes Storage, Compute, and Project usage allowances. The Launch permits extra compute usage. The Scale plans permits extra compute, storage, and project usage.
This topic describes Storage, Compute, and Project usage metrics in more detail so that you can better manage your plan allowances and extra usage.
The following table outlines data storage allowances for each Neon plan.
Extra storage is available with the Scale plan. Extra storage is billed for in units of 10 GiB. For example, the Scale plan has an allowance of 50 GiB included in the plan's monthly fee. If you go over 50 GiB of storage, you are automatically billed for extra storage in increments of 10 GiB for the price stated on our pricing page. For example, as soon as you go over your allowance, say by 1 GiB, you are billed for one 10 GiB unit of storage. If you go over by more than 10 GiB, you will be billed for two 10 GiB units of storage, and so on.
What is "storage" in Neon?
Neon storage uses copy-on-write branching to keep storage size as small as possible. This can make it hard to visualize "how big is my database", since branches with a shared history don't immediately add to storage. Storage size is a combination of your total data plus the shared change history that is used to enable branching-related features like point-in-time restore, query testing, and reset from parent.
Storage is the total volume of data and history stored in Neon, measured in gibibytes (GiB). It includes the following:
Current data size
The size of all databases in your Neon projects. You can think of this as a snapshot of your data at a point in time.
Neon retains a history of changes for all branches to support point-in-time restore.
Point-in-time restore is the ability to restore data to an earlier point in time. Neon retains a history of changes in the form of WAL records. You can configure the history retention period. See Point-in-time restore. WAL records that age out of the history retention period are evicted from storage and no longer count toward storage.
A database branch is a virtual snapshot of your data at the point of branch creation combined with WAL records that capture the branch's data change history from that point forward. When a branch is first created, it adds no storage. No data changes have been introduced yet, and the branch's virtual snapshot still exists in the parent branch's history, which means that it shares this data in common with the parent branch. A branch begins adding to storage when data changes are introduced or when the branch's virtual snapshot falls out of the parent branch's history, in which case the branch's data is no longer shared in common. In other words, branches add storage when you modify data or allow the branch to age out of the parent branch's history.
Database branches can also share a history. For example, two branches created from the same parent at or around the same time share a history, which avoids additional storage. The same is true for a branch created from another branch. Wherever possible, Neon minimizes storage through shared history. Additionally, to keep storage to a minimum, Neon takes a new branch snapshot if the amount of data changes grows to the point that a new snapshot consumes less storage than retained WAL records.
The Storage is calculated in gibibytes (GiB), otherwise known as binary gigabytes. One gibibyte equals 230 or 1,073,741,824 bytes.
The following table outlines compute allowances for each Neon plan.
|Always-available primary branch compute, 20 active hours/month (5 compute hours) on branch computes
|Up to 1,200 active hours/month (300 compute hours)
|Up to 3,000 active hours/month (750 compute hours)
Extra compute usage is available with the Launch and Scale plans. Extra compute usage is billed for by compute hour. For example, the Launch plan has an allowance of 300 compute hours included in the plan's monthly fee. If you use additional compute hours, you are billed for those at the compute-hour price stated on our pricing page.
What are active hours?
Active hours measures the amount of time a compute is active, rather than idle when suspended due to inactivity. The time that your compute is idle is not counted toward compute usage.
What is a compute hour?
A compute hour is 1 hour is equal to one active hour for a compute with 1 vCPU. If you have a compute with .25 vCPU, as you would on the Neon Free Tier, it would require 4 active hours to use 1 compute hour. On the other hand, if you have a compute with 4 vCPU, it would only take 15 minutes to use 1 compute hour.
How Neon compute features affect usage
Compute-hour usage in Neon is affected by autosuspend, autoscaling, and your minimum and maximum compute size configuration. With these features enabled, you can get a sense of how your compute usage might accrue in the following graph.
You can see how compute size scales between your minimum and maximum CPU settings, increasing and decreasing compute usage: compute size never rises above your max level, and it never drops below your minimum setting. With autosuspend, no compute time at all accrues during inactive periods. For projects with inconsistent demand, this can save significant compute usage.
Compute usage details
Compute hour usage is calculated by multiplying compute size by active hours. Neon measures compute size at regular intervals and averages those values to calculate your compute hour usage.
Active hours is the amount of time that your computes have been active. This includes all computes in your Neon project but excludes time when computes are in an
Idle state due to auto-suspension (scale-to-zero).
Compute size in Neon is measured in Compute Units (CUs). One CU has 1 vCPU and 4 GB of RAM. A Neon compute can have anywhere from .25 to 7 CUs, as outlined below:
A connection from a client or application activates a compute. Activity on the connection keeps the compute in an
Active state. A defined period of inactivity (5 minutes by default) places the compute into an
Factors that affect active hours include:
- The number of active computes
- The size of each compute
- The Autosuspend feature, which suspends a compute after 5 minutes of inactivity by default. Users on paid plans can configure the autosuspend timeout or disable it entirely.
- The Autoscaling feature, which allows you to set a minimum and maximum compute size. Compute size automatically scales up and down between these boundaries based on workload.
Neon uses a small amount of compute time, included in your billed compute hours, to perform a periodic check to ensure that your computes can start and read and write data. See Availability Checker for more information.
The compute hour usage calculation is as follows:
Estimate your compute hour usage
To estimate what your compute hour usage might be per month:
Determine the compute size you require, in Compute Units (CUs).
Estimate the amount of active hours per month for your compute(s).
Input the values into the compute hours formula:
For example, this is a calculation for a 2 vCPU compute that is active for all hours in a month (approx. 730 hours):
This calculation is useful when trying to select the right Neon plan or when estimating the extra compute usage you might need.
In Neon, everything starts with a project. A project is a container for your branches, databases, roles, and other resources and settings. A project also defines the region your data and resources reside in. We typically recommend creating a project for each application or each client. In addition to organizing objects, projects are a way to track storage and compute usage by application or client.
The following table outlines project allowances for each Neon plan.
- When you reach your limit on the Free Tier or Launch plan, you cannot create additional projects. Instead, you can upgrade to the Launch or Scale plan, which offer allowances of 10 and 50 projects, respectively.
- Extra projects are available with the Scale plan in increments of 10. If you use more than 50 projects, you are automatically billed for an extra package of 10 projects for the price stated on our pricing page. For example, if you use 51 projects, you are billed for a package of 10 projects. If you use 61 projects, you are billed for two packages of 10 projects, and so on.
Last updated on