PHPackages                             joomla/filesystem - 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. [Framework](/categories/framework)
4. /
5. joomla/filesystem

ActiveJoomla-package[Framework](/categories/framework)

joomla/filesystem
=================

Joomla Filesystem Package

4.2.0(1w ago)12410.5k↑81.4%20[6 issues](https://github.com/joomla-framework/filesystem/issues)[2 PRs](https://github.com/joomla-framework/filesystem/pulls)7GPL-2.0-or-laterPHPPHP ^8.3.0CI failing

Since Jun 4Pushed 1w ago13 watchersCompare

[ Source](https://github.com/joomla-framework/filesystem)[ Packagist](https://packagist.org/packages/joomla/filesystem)[ Docs](https://github.com/joomla/joomla-framework-filesystem)[ RSS](/packages/joomla-filesystem/feed)WikiDiscussions 3.x-dev Synced 2d ago

READMEChangelog (10)Dependencies (12)Versions (40)Used By (7)Security (1)

The Filesystem Package [![Build Status](https://github.com/joomla-framework/filesystem/actions/workflows/ci.yml/badge.svg?branch=3.x-dev)](https://github.com/joomla-framework/filesystem)
==========================================================================================================================================================================================

[](#the-filesystem-package-)

[![Latest Stable Version](https://camo.githubusercontent.com/89e24979c15e8e3b0db1f2d5c22e0c91b3e73d0731309411e44dd667c0db33e3/68747470733a2f2f706f7365722e707567782e6f72672f6a6f6f6d6c612f66696c6573797374656d2f762f737461626c65)](https://packagist.org/packages/joomla/filesystem)[![Total Downloads](https://camo.githubusercontent.com/b2d6b1b16daa57069499aab5608c1f58107c5c74cbf50e4bee4a54641d3007ed/68747470733a2f2f706f7365722e707567782e6f72672f6a6f6f6d6c612f66696c6573797374656d2f646f776e6c6f616473)](https://packagist.org/packages/joomla/filesystem)[![Latest Unstable Version](https://camo.githubusercontent.com/7b876da39984b4b5a02773a53cbbbfdbbcae36b12e66316b9f47efdfab48f663/68747470733a2f2f706f7365722e707567782e6f72672f6a6f6f6d6c612f66696c6573797374656d2f762f756e737461626c65)](https://packagist.org/packages/joomla/filesystem)[![License](https://camo.githubusercontent.com/2e9dac6e026ad71b1652ff4816b015bceaa4484ef88a6379d39e137895bc2a6e/68747470733a2f2f706f7365722e707567782e6f72672f6a6f6f6d6c612f66696c6573797374656d2f6c6963656e7365)](https://packagist.org/packages/joomla/filesystem)

File upload example
-------------------

[](#file-upload-example)

```
use Joomla\Filesystem\File;

$file = $this->input->files->get('file');

$config = array(
    'extensions'    => 'jpg,jpeg,gif,png,pdf,doc,docx',
    'max_size'      => 30000000, // 30 MB
    'folder'        => 'documents'
);

// Check there is some file to upload
if (empty($file['name']))
{
    return;
}

// Check max size
if ($file['size'] > $config['max_size'])
{
    throw new \RuntimeException('Uploaded file size (' . round($file['size'] / 1000) . ' kB) is greater than allowed size (' . round($config['max_size'] / 1000) . ' kB).');
}

$config['extensions'] = explode(',', $config['extensions']);

// Get File extension
$ext = strtolower(substr($file['name'], (strrpos($file['name'], '.') + 1)));

// Sanitize allowed extensions
foreach ($config['extensions'] as &$extension)
{
    $extension = str_replace('.', '', trim(strtolower($extension)));
}

// Check allowed extensions
if (!in_array($ext, $config['extensions']))
{
    throw new \RuntimeException('Uploaded file extension (' . $ext . ') is not within allowed extensions (' . implode(',', $config['extensions']) . ')');
}

$path = JPATH_ROOT . '/' . $config['folder'] . '/' . File::makeSafe($file['name']);

File::upload($file['tmp_name'], $path);
```

Changes From 1.x
----------------

[](#changes-from-1x)

### Patcher

[](#patcher)

In 1.x, the second parameter of the `add` and `addFile` methods was optional. In 2.0, this parameter is required. This parameter requires the root path of the source which you are patching.

Installation via Composer
-------------------------

[](#installation-via-composer)

Add `"joomla/filesystem": "~3.0"` to the require block in your composer.json and then run `composer install`.

```
{
	"require": {
		"joomla/filesystem": "~3.0"
	}
}
```

Alternatively, you can simply run the following from the command line:

```
composer require joomla/filesystem "~3.0"
```

If you want to include the test sources, use

```
composer require --prefer-source joomla/filesystem "~3.0"
```

###  Health Score

69

—

FairBetter than 100% of packages

Maintenance88

Actively maintained with recent releases

Popularity47

Moderate usage in the ecosystem

Community37

Small or concentrated contributor base

Maturity90

Battle-tested with a long release history

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~140 days

Recently: every ~79 days

Total

35

Last Release

8d ago

Major Versions

2.0.2 → 3.0.02023-10-07

3.1.2 → 4.0.02025-07-23

3.1.3 → 4.0.12025-08-14

3.2.0 → 4.1.02025-08-27

3.3.0 → 4.2.02026-06-25

PHP version history (8 changes)1.0-alphaPHP &gt;=5.3.10

1.3.1PHP ^5.3.10|~7.0

2.0.0-betaPHP ^7.2.5

2.0.0-rcPHP ^7.2.5|^8.0

1.6.1PHP ^5.3.10|^7.0|^8.0

2.0.2PHP ^7.2.5|~8.0.0|~8.1.0

3.0.0PHP ^8.1.0

4.0.0PHP ^8.3.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/305a2164440014dcef9ac681c139fe5e8a1ce1d7a8c3b3cfb828497729a4c70e?d=identicon)[wilsonge](/maintainers/wilsonge)

![](https://avatars.githubusercontent.com/u/42966168?v=4)[Release-Joomla](/maintainers/release-joomla)[@release-joomla](https://github.com/release-joomla)

![](https://avatars.githubusercontent.com/u/313866?v=4)[Hannes Papenberg](/maintainers/Hackwar)[@Hackwar](https://github.com/Hackwar)

---

Top Contributors

[![mbabker](https://avatars.githubusercontent.com/u/368545?v=4)](https://github.com/mbabker "mbabker (137 commits)")[![nibra](https://avatars.githubusercontent.com/u/827605?v=4)](https://github.com/nibra "nibra (40 commits)")[![Hackwar](https://avatars.githubusercontent.com/u/313866?v=4)](https://github.com/Hackwar "Hackwar (39 commits)")[![dongilbert](https://avatars.githubusercontent.com/u/718028?v=4)](https://github.com/dongilbert "dongilbert (20 commits)")[![SniperSister](https://avatars.githubusercontent.com/u/498096?v=4)](https://github.com/SniperSister "SniperSister (16 commits)")[![wilsonge](https://avatars.githubusercontent.com/u/1986000?v=4)](https://github.com/wilsonge "wilsonge (13 commits)")[![Achal-Aggarwal](https://avatars.githubusercontent.com/u/3330262?v=4)](https://github.com/Achal-Aggarwal "Achal-Aggarwal (11 commits)")[![zero-24](https://avatars.githubusercontent.com/u/2596554?v=4)](https://github.com/zero-24 "zero-24 (8 commits)")[![richard67](https://avatars.githubusercontent.com/u/7413183?v=4)](https://github.com/richard67 "richard67 (7 commits)")[![joomla-jenkins](https://avatars.githubusercontent.com/u/929228?v=4)](https://github.com/joomla-jenkins "joomla-jenkins (5 commits)")[![PhilETaylor](https://avatars.githubusercontent.com/u/400092?v=4)](https://github.com/PhilETaylor "PhilETaylor (4 commits)")[![HLeithner](https://avatars.githubusercontent.com/u/1497730?v=4)](https://github.com/HLeithner "HLeithner (4 commits)")[![eddieajau](https://avatars.githubusercontent.com/u/700871?v=4)](https://github.com/eddieajau "eddieajau (4 commits)")[![heelc29](https://avatars.githubusercontent.com/u/66922325?v=4)](https://github.com/heelc29 "heelc29 (4 commits)")[![brianteeman](https://avatars.githubusercontent.com/u/1296369?v=4)](https://github.com/brianteeman "brianteeman (4 commits)")[![realityking](https://avatars.githubusercontent.com/u/628508?v=4)](https://github.com/realityking "realityking (3 commits)")[![escopecz](https://avatars.githubusercontent.com/u/1235442?v=4)](https://github.com/escopecz "escopecz (2 commits)")[![pborreli](https://avatars.githubusercontent.com/u/77759?v=4)](https://github.com/pborreli "pborreli (2 commits)")[![artur-stepien](https://avatars.githubusercontent.com/u/2000754?v=4)](https://github.com/artur-stepien "artur-stepien (1 commits)")[![ianmacl](https://avatars.githubusercontent.com/u/176534?v=4)](https://github.com/ianmacl "ianmacl (1 commits)")

---

Tags

filesystemjoomlajoomla-frameworkphpfilesystemframeworkjoomla

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP\_CodeSniffer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/joomla-filesystem/health.svg)

```
[![Health](https://phpackages.com/badges/joomla-filesystem/health.svg)](https://phpackages.com/packages/joomla-filesystem)
```

###  Alternatives

[joomla/filter

Joomla Filter Package

151.5M10](/packages/joomla-filter)[joomla/http

Joomla HTTP Package

18734.9k15](/packages/joomla-http)[joomla/application

Joomla Application Package

23445.7k13](/packages/joomla-application)[joomla/registry

Joomla Registry Package

18526.3k21](/packages/joomla-registry)[joomla/di

Joomla DI Package

15433.2k12](/packages/joomla-di)[joomla/oauth2

Joomla OAuth2 Package

11340.0k2](/packages/joomla-oauth2)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
