PHPackages                             codeinc/human-readable-file-size - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. codeinc/human-readable-file-size

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

codeinc/human-readable-file-size
================================

Human readable file size

1.0.0(6y ago)542.8k—0.6%21MITPHPPHP &gt;=7.4

Since Jan 31Pushed 2y ago1 watchersCompare

[ Source](https://github.com/codeinchq/human-readable-file-size)[ Packagist](https://packagist.org/packages/codeinc/human-readable-file-size)[ Docs](https://github.com/codeinchq/human-readable-file-size)[ RSS](/packages/codeinc-human-readable-file-size/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)DependenciesVersions (2)Used By (1)

Human readable file size
========================

[](#human-readable-file-size)

This PHP 7 library, strongly inspired by [Jeffrey Sambells' blog post](http://jeffreysambells.com/2012/10/25/human-readable-filesize-php), computes a size in bytes in a human readable form.

Installation
------------

[](#installation)

This library is available through [Packagist](https://packagist.org/packages/codeinc/human-readable-file-size)and can be installed using [Composer](https://getcomposer.org/):

```
composer require codeinc/human-readable-file-size
```

Usage
-----

[](#usage)

### Simple usage

[](#simple-usage)

```
