Database Partition Size Calculator

Enter your table row count, average row size, and target partition size to get partition count, size per partition, and storage estimates.

Use the Database Partition Size Calculator

Table Parameters

Number of rows currently in (or expected in) the table.

Average bytes per row including all columns.

Maximum size each partition should reach.

Extra space for indexes, free pages, TOAST, etc.

Fill in the parameters on the left and click Calculate Partitions.

Summary

This calculator helps database engineers plan table partitioning by computing the recommended number of partitions, rows per partition, and total storage requirements. Supply your row count, average row size, and desired target partition size and the tool outputs all key metrics instantly in the browser — no server-side computation required. It also accounts for per-partition overhead such as indexes and free-space pages so your estimates reflect real-world disk usage.

How it works

  1. Enter the total number of rows in your database table.
  2. Specify the average row size in bytes (or use the byte unit selector).
  3. Set your target partition size — the maximum size each partition should hold.
  4. The calculator outputs the recommended partition count, actual rows per partition, and total storage.
  5. Review the storage breakdown to plan disk capacity and rebalancing schedules.

Use cases

  • Plan MySQL, PostgreSQL, or MariaDB table partitioning before a large migration.
  • Estimate how many shards a Cassandra or MongoDB collection needs.
  • Size partitions for time-series tables where each partition covers a date range.
  • Capacity-plan disk storage for a growing transactional table.
  • Validate that existing partition counts are still appropriate after data growth.
  • Compare partition strategies by adjusting the target size and observing trade-offs.

Frequently Asked Questions

Last updated: 2026-06-11 · Reviewed by Nham Vu