PHPackages                             matrixpro/csv-reader - 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. matrixpro/csv-reader

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

matrixpro/csv-reader
====================

Reads CSV files.

04PHP

Since Mar 6Pushed 7y ago1 watchersCompare

[ Source](https://github.com/Matrixpro/csv-reader)[ Packagist](https://packagist.org/packages/matrixpro/csv-reader)[ RSS](/packages/matrixpro-csv-reader/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependenciesVersions (1)Used By (0)

MatrixPro CSV Reader
====================

[](#matrixpro-csv-reader)

[![License](https://camo.githubusercontent.com/30597ff9a350144f03bffdd9183e16468e0b3ca1193e1d08591d992622738d55/687474703a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](https://tldrlegal.com/license/mit-license)

Reads CSV files and returns an array containing all or some of the CSV rows. For large CSV files you may specify how many rows to work with at a time and where to start via the file pointer position. Compatible with large CSV datasets (tested on 4gb+ files).

Install via composer:

```
composer require matrixpro/csv-reader

```

Usage
-----

[](#usage)

Pass a CSV file handle to the reader and use the getRows() method.

```
$handle = fopen('path/to/file.csv', "r");
$reader = new CsvReader($handle);
$rows = $reader->getRows();
```

#### Get First Five Rows

[](#get-first-five-rows)

Optionally save the position so you can process some rows and pick it up again later.

```
$first_five_rows = $reader->getRows(5);
$csv_position = $reader->getPosition();
```

#### Get Next Five Rows

[](#get-next-five-rows)

Use the position saved earlier to continue processing the file.

```
$second_five_rows = $reader->getRows(5, $csv_position);
```

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity38

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/33a94deef0e5a61d5b791b5d19185dec7eb621a6a714c96e1eb6850534aa0398?d=identicon)[MatrixPro](/maintainers/MatrixPro)

---

Top Contributors

[![Matrixpro](https://avatars.githubusercontent.com/u/6796027?v=4)](https://github.com/Matrixpro "Matrixpro (1 commits)")

### Embed Badge

![Health badge](/badges/matrixpro-csv-reader/health.svg)

```
[![Health](https://phpackages.com/badges/matrixpro-csv-reader/health.svg)](https://phpackages.com/packages/matrixpro-csv-reader)
```

PHPackages © 2026

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