azurerm_ mssql_ elasticpool cost estimation
A shared pool of resources for many Azure SQL databases. Priced per pool vCore-hour (or DTU) plus pool storage, amortizing capacity across databases.
An azurerm_
The pool is priced on its provisioned capacity, not per database. In the vCore model, you pay per pool vCore-hour, roughly $0.1129/vCore-hour for General Purpose Gen5, plus pool storage per GB-month. A 4-vCore GP pool runs about $330/month for compute regardless of whether it holds 5 databases or 50. The DTU model is similar but measured in eDTUs. Databases added to the pool don't each incur a separate compute charge.
c3x reads sku_
Terraform example
A minimal but realistic configuration that C3X can estimate.
resource "azurerm_mssql_elasticpool" "shared" {
name = "shared-pool"
resource_group_name = azurerm_resource_group.db.name
location = "eastus"
server_name = azurerm_mssql_server.main.name
sku {
name = "GP_Gen5"
tier = "GeneralPurpose"
family = "Gen5"
capacity = 4
}
max_size_gb = 100
per_database_settings {
min_capacity = 0
max_capacity = 2
}
}Pricing dimensions
What you actually pay for when you provision azurerm_.
| Dimension | Unit | What's being charged |
|---|---|---|
| Pool vCores | per vCore-hour | Provisioned pool compute, shared by all databases in the pool. c3x prices the capacity at 730 hours/month. $0.1129/vCore-hour (GP Gen5) |
| Pool storage | per GB-month | Storage allocated to the pool (max_ $0.115/GB-month |
Sample C3X output
Example output from c3x estimate (4-vCore GP pool, 100 GB):
azurerm_mssql_elasticpool.shared
├─ Pool vCores (GP Gen5, 4) 2,920 vCore-hours $329.67
└─ Pool storage 100 GB-month $11.50
OVERALL TOTAL $341.17Optimization tips
Common ways to reduce azurerm_ cost without changing the workload.
Pool databases with non-overlapping peaks
Consolidation vs separate DBsElastic pools save money when member databases peak at different times, so the pool's capacity covers the aggregate, not the sum of individual peaks. Databases that all spike together don't benefit.
Right-size pool capacity to aggregate peak
Proportional to over-provisioningProvision pool vCores for the combined peak demand, not the sum of each database's max. Monitor pool utilization and trim capacity that stays unused.
Apply Azure Hybrid Benefit and reservations
Up to ~50% combinedPools support Azure Hybrid Benefit (license savings) and reserved capacity, stacking the same ~30-40% and ~30% discounts as single databases.
FAQ
How does c3x estimate an elastic pool?
It reads sku_
Do databases in the pool cost extra?
No. Member databases share the pool's provisioned compute and storage; they don't each incur a separate compute charge. That sharing is the whole point of a pool.
When is a pool cheaper than separate databases?
When you have many databases with uneven, non-overlapping load. The pool covers the aggregate peak instead of each database carrying its own idle headroom. For a few steadily-busy databases, single databases may be simpler and comparable.
Does the estimate change for the DTU model?
The model is analogous: DTU pools bill per eDTU. c3x reads the tier and capacity and prices accordingly. The vCore model is more common for new deployments.
Can I use Hybrid Benefit on a pool?
Yes. vCore-model pools support Azure Hybrid Benefit and reserved capacity, the same license and commitment discounts available to single databases and managed instances.
Related resources
More Azure resources
Further reading
Estimate this resource in your own Terraform
Free, open source, no API key. C3X parses your Terraform and shows line-item cost for every resource, including azurerm_.