Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

ahmetturgut's avatar

Built a Laravel package for exporting huge XLSX files without eating all your memory

Hey folks,

I kept running into issues when trying to export really large datasets to Excel in Laravel. Most libraries either blew up the memory usage, required writing to disk first, or just crawled when the row count got high.

So I ended up building a package that streams XLSX files directly (no temp files), keeps memory usage super low (~2MB even with millions of rows), and can upload straight to S3 with multipart uploads.

For context, I tested it with 4.6M+ rows (over 500MB) and it handled it smoothly. 🚀 If you’ve ever had to deal with large exports in Laravel, this might save you some headaches.

👉 Repo: https://github.com/turgutahmet/kolay-xlsx-stream

3 likes
4 replies
jlrdw's avatar

Thanks for sharing this package.

1 like
ahmetturgut's avatar

I will also make improvements to docx in the future. Thank you.

Please or to participate in this conversation.