NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
npm, #1989 most downloaded on npm
Lightweight, zero-dependency JavaScript utility to convert bytes to human-readable strings with localization support
Latest stable
11.0.35
Last release 4 days ago
18 Nov 2026
Ships unpredictably
gaps range from 8 days to 6 months
Nearly every release is documented
notes for 56 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
15 years old
160 releases · first in 2012
Drag across the ruler to compare, or tap a release to open it.
Fixes formatting of negative values that round to zero so they render like any other zero. Also bumps the rollup dev dependency to 4.68.3.
Fixes formatting of negative values that round to zero so they render like any other zero. Also bumps the rollup dev dependency to 4.68.3.
Fixes a scientific notation leak in precision output, preventing values from being displayed in scientific notation when they should not be.
Fixes a scientific notation leak in precision output, preventing values from being displayed in scientific notation when they should not be.
Your coding agent can read these notes before it upgrades. Set up the MCP server →
Fixes precision handling so the value is no longer rounded twice when a precision is set, which corrected results at unit boundaries such as 0.986 GiB
Fixes precision handling so the value is no longer rounded twice when a precision is set, which corrected results at unit boundaries such as 0.986 GiB. Also reverts the earlier decimal-unit precision change. Includes rebuilt distributions and updated changelog.
Fixes the standard option so uppercase spellings are accepted. Also includes development dependency updates for oxlint, rollup, and oxfmt.
Fixes the standard option so uppercase spellings are accepted. Also includes development dependency updates for oxlint, rollup, and oxfmt.
Fixes precision handling so the significant-digit pass runs on the un-rounded value for decimal units, preventing double-rounding and premature unit b
Fixes precision handling so the significant-digit pass runs on the un-rounded value for decimal units, preventing double-rounding and premature unit bumps. Includes routine dependency updates for rollup, oxlint, and oxfmt.
12 November 2026
#408#404#407#406#405#402#401#400#398#397#399Restricts the roundingMethod option to the supported set (round, floor, and ceil), rejecting arbitrary Math functions like sqrt and abs with a TypeErr
Restricts the roundingMethod option to the supported set (round, floor, and ceil), rejecting arbitrary Math functions like sqrt and abs with a TypeError. Includes dependency bumps for rollup, oxlint, and oxfmt, plus documentation updates for the BigInt input range and README/AGENTS.md structure.
3 November 2026
#396#395#394#393#392#391#389#386#388#387#385#384#383#390 #390 #390Fixes formatting of precision values with the default locale, so values like 1234 render as 1,234 B instead of 1234.00 B. Includes dev-dependency bump
Fixes formatting of precision values with the default locale, so values like 1234 render as 1,234 B instead of 1234.00 B. Includes dev-dependency bumps for oxlint, oxfmt, and rollup.
Fixes the locale option being ignored when precision is set, so values like 1.2 render with the locale's decimal separator (e.g. 1,2 for Swedish) inst
Fixes the locale option being ignored when precision is set, so values like 1.2 render with the locale's decimal separator (e.g. 1,2 for Swedish) instead of always using a period.
Fixes small values and custom separators leaking scientific notation, so values like 1e-9 render as full decimals instead of collapsing to zero or exp
Fixes small values and custom separators leaking scientific notation, so values like 1e-9 render as full decimals instead of collapsing to zero or exposing exponent form. Includes dependency bumps for rollup, oxfmt, and oxlint.
21 October 2026
#375#369#374#372#371#370#368#367Fixes the zero-value formatting path so the locale, localeOptions, and separator options are honored consistently with non-zero values. Includes the v
Fixes the zero-value formatting path so the locale, localeOptions, and separator options are honored consistently with non-zero values. Includes the v11.0.26 release commit and updates to development dependencies.
11 October 2026
#366#365#364#363#362#361#360#359#358#357Fixes BigInt precision loss in filesize() so values above Number.MAX_SAFE_INTEGER are preserved accurately, corrects README accuracy errors, and updat
Fixes BigInt precision loss in filesize() so values above Number.MAX_SAFE_INTEGER are preserved accurately, corrects README accuracy errors, and updates development dependencies.
26 September 2026
#356#355#353#352#351#350#349#348#347#346#354Includes a fix hardening input validation and edge-case handling in filesize() — covering BigInt overflow, non-integer and string exponents, negative
Includes a fix hardening input validation and edge-case handling in filesize() — covering BigInt overflow, non-integer and string exponents, negative fullform singular naming, sign preservation on round-to-zero, precision range validation, invalid output handling, and scientific notation leak prevention. Also includes dependency updates for oxlint, oxfmt, and auto-changelog.
14 September 2026
#345#344#342#341#340#339#338Includes a fix for negative values losing precision trailing zeros when using the precision option. Development dependencies (oxlint, oxfmt, rollup, a
Includes a fix for negative values losing precision trailing zeros when using the precision option. Development dependencies (oxlint, oxfmt, rollup, actions/setup-node) have been updated across 20 commits.
3 September 2026
#336#331#335#334#333#332#330#329#328#326#325#324#323#322#321#320#319#318#317#316#315Includes a fix for plural fullform name handling with comma decimal separators, and commits the build artifacts for the release.
Includes a fix for plural fullform name handling with comma decimal separators, and commits the build artifacts for the release.
Includes fixes for honoring the pad option on zero values and returning the final exponent from the output. Dependency updates are also included.
Includes fixes for honoring the pad option on zero values and returning the final exponent from the output. Dependency updates are also included.
Includes a fix for clamping negative forced exponents to 0 in helpers. Dependency updates bump oxlint from 1.71.0 to 1.73.0 and oxfmt from 0.56.0 to 0
Includes a fix for clamping negative forced exponents to 0 in helpers. Dependency updates bump oxlint from 1.71.0 to 1.73.0 and oxfmt from 0.56.0 to 0.57.0.
Resolves audit findings including padding truncation when separator and pad are both set, clarifies isNaN usage, and replaces JSON deep clone with str
Resolves audit findings including padding truncation when separator and pad are both set, clarifies isNaN usage, and replaces JSON deep clone with structuredClone in the partial function. Documentation updates add issue templates, a security policy, and updates the contributing guide.
Fixes a locale padding bug that dropped digits when pad was combined with a locale. Dependency updates cover oxlint, oxfmt, rollup, auto-changelog, an
Fixes a locale padding bug that dropped digits when pad was combined with a locale. Dependency updates cover oxlint, oxfmt, rollup, auto-changelog, and actions/checkout. Documentation updates include a PR template convention, AGENTS.md restructuring, and README cleanup.
25 June 2026
#295#292#294#293#291#290#289#288#287#286#285#284#283#282#281#280#279#278#277#276#275#274#273#272#271#270#269#268#267#266#265#264#263#262#260#259#25843320d88f97c2a99136ffNothing published for this version
refactor: extract delegate functions from filesize for better SRP `#257`
19 April 2026
#257#256#255#254#253#252#251#250767bf07bf3df96be4ffbbBump handlebars from 4.7.8 to 4.7.9 `#249`
Major refactor, documentation overhaul, and community best practices `#248`
25 March 2026
#248#246#245#243#242#241#239#236#235#234#233#232#231#230#229#228#227#226#225#224#223#222#221#220#219#218#217#216#215#214#213#212#211#210#209#2080a79afd443e3ccFixing links in the README.md header `bbe910f`
Version bump, updating CHANGELOG.md `88edbb0`
Updating CHANGELOG.md `df0978a`
> 19 September 2025 - Version bump `cc9e109` - Updating README.md `bc34e1d`
Updating documentation `f38cabf`
Fixing 'precision' some moar `#205`
Fixing the upper boundary of 'precision' `#204`
Taking a mulligan on 'precision' `#203`
Revert "Fixing the output when supplying 'precision' (#201)" `c5edf39`
Fixing how 'precision' adjusts the exponent if there's digits `#202`
Fixing the output when supplying 'precision' `#201`
19 September 2025
#201#199#198#197#196#195#194#193#192#191017e5b1ec20636ef70bf8Returning 'bigint' to 'filesize.d.ts' & fixing docblock `#190`
Nothing published for this version
Fixing regression due to rollup config, fixes #185 `#185`
Fixing implementation of 'pad' such that 'separator' is not required for it to be applied, fixes #184 `#184`
Fixing type def of 'partial()' `0e1516a`
fix: add bigint in filesize.d.ts `#183`
fix: input type should accept string `#181`
Rework types to allow Parameters<typeof filesize> to function properly `#180`
21 March 2024
Fixing tests to use strictEqual() `6b4b108`
Allow passing options without output property `#174`
Version bump 'cause npm has inane rules for releases `5544cb7`
Revert "Tweaking types and removing any usage" `3aee3e8`
Tweaking types and removing any usage `#172`
fixup: Add interface for filesize options object `#171`
Updating copyright year in README.md & LICENSE, updating dependencies `4de5566`
Setting engines.node to >= 10.4.0 for lowest version supporting BigInt, fixing npm run build for windows (needs gow) `0a4d329`
Reverting revert to default export, removing browser key from package.json as it's redirection away from main or module is what breaks webpack, fixes
12 December 2022
#164browser key from package.json as it's redirection away from main or module is what breaks webpack, fixes #162 #162ee1a97771a633687f817cNothing published for this version
Switching back to a default export for webpack issues (unsure of where the issue is atm), fixes #162 `#162`
Fixing rollup config (copy/pasta), version bump to release, fixes #162 `#162`
Lowering minimum version to 14.0.0, fixes #161 `#161`
Nothing published for this version
Adding invaid base 10 iec test set, building `38221a0`
Fixing base 2 jedec regression with refactoring `#158`
27 June 2022
#158base2 tests explicitly set to jedec standard to expose logic error 1281269standard if base has been specified, updating bit tests in base2Jedec set dc7c3a4f924463Fix regression of output from 9.x.x `#155`
Updating README.md to remove examples, fixes #154 `#154`
One column per quarter.