# File size display format (scripting for column)

**URL:** <https://community.mp3tag.de/t/file-size-display-format-scripting-for-column/52360>\
**Category:** Support\
**Created:** [March 14, 2021, 2:11am UTC](https://community.mp3tag.de/t/file-size-display-format-scripting-for-column/52360 "2021-03-14T02:11:06Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Quisquose](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/q/ea666f/32.png) [@Quisquose](https://community.mp3tag.de/u/Quisquose)\
**Post date:** [March 14, 2021, 2:11am UTC](https://community.mp3tag.de/t/file-size-display-format-scripting-for-column/52360/1 "2021-03-14T02:11:06Z")

</div>

I have been using the `%_file_size%` value to automatically display **KB** , **MB** or **GB** units depending on the file size.

It works fine, but the units seem to switch based upon _binary_ values instead of _decimal_ values (i.e. 1024 instead of 1000). Using binary values for file sizes makes sense because it's what most people would want and expect for such a value, but the units really should be displayed as KiB, MiB, and GiB and not KB, MB and GB (which are decimal units).

In my case, I want to limit the number of displayed characters to no more than 3 digits and 2 decimal places (plus the 2 letters for the unit size) but `%_file_size%` does not allow me to do this.

I would therefore like to recreate the same automatic unit-changing ability of the `%_file_size%` value, but with the changes occurring at 1000 instead of 1024 (so that 999.99 is the highest value to be displayed before switching up to the next file-size unit)

Example: 999.99 MB then 1.00 GB (instead of 1000.00 MB which is what I get now)

**Can anybody please let me know what scripting I would need to use to achieve this?**

Thanks!

·

* * *

Suggestion:

To avoid requiring manual scripting work-arounds in future, perhaps Florian could consider adding new 'human-readable' values for decimal and binary sizes to prevent confusion:

`%_file_size_decimal%` (displayed with KB, MB, GB, TB units)  
`%_file_size_binary%` (displayed with KiB, MiB, GiB, TiB units)

The existing `%_file_size%` value could be left in place (to retain backwards-compatibility and prevent breaking existing scripts) because it would offer a different option to the two new values (i.e. a kind of "hybrid": binary size but with decimal display units).

People can then choose whichever one best suits their needs.

---

<div class="post-metadata">

**Author:** ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)\
**Post date:** [February 9, 2026, 12:29pm UTC](https://community.mp3tag.de/t/file-size-display-format-scripting-for-column/52360/2 "2026-02-09T12:29:07Z")

</div>


