PHPackages                             cryde/json-text-extractor - 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. cryde/json-text-extractor

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

cryde/json-text-extractor
=========================

Helper that will extract JSON from plain text

0.0.3(3y ago)128.7k—6.2%1[2 issues](https://github.com/Cryde/json-text-extractor/issues)MITPHP

Since May 7Pushed 3y ago1 watchersCompare

[ Source](https://github.com/Cryde/json-text-extractor)[ Packagist](https://packagist.org/packages/cryde/json-text-extractor)[ RSS](/packages/cryde-json-text-extractor/feed)WikiDiscussions main Synced 2d ago

READMEChangelogDependencies (3)Versions (4)Used By (0)

Json Text Extractor
===================

[](#json-text-extractor)

Small library that will help extract JSON from plain text

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

[](#installation)

```
composer require cryde/json-text-extractor

```

Usage
-----

[](#usage)

The usage is pretty straightforward.

```
use Cryde\JsonTxtExtractor\JsonTextExtractor;

$str =
  string(16) "{"key": "value"}"
}

*/
```

Use cases
---------

[](#use-cases)

- extract JSON from strings returned by ChatGPT : sometimes (even though you explicit asked to not do that) it will add some explanations around the JSON returned
- tell me if you have other use cases

Feedback / Bugs
---------------

[](#feedback--bugs)

If you have any feedback, please open an issue.
I may not have covered all cases. If you have one not covered add it to your issue.
Do not hesitate to open an issue if you have an idea to improve this small library.

###  Health Score

25

—

LowBetter than 35% of packages

Maintenance17

Infrequent updates — may be unmaintained

Popularity31

Limited adoption so far

Community5

Small or concentrated contributor base

Maturity37

Early-stage or recently created project

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 ~3 days

Total

3

Last Release

1148d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1662950?v=4)[Jérémy](/maintainers/Cryde)[@Cryde](https://github.com/Cryde)

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/cryde-json-text-extractor/health.svg)

```
[![Health](https://phpackages.com/badges/cryde-json-text-extractor/health.svg)](https://phpackages.com/packages/cryde-json-text-extractor)
```

###  Alternatives

[laravel/horizon

Dashboard and code-driven configuration for Laravel queues.

4.2k95.4M306](/packages/laravel-horizon)[civicrm/civicrm-core

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

751291.4k43](/packages/civicrm-civicrm-core)[illuminate/support

The Illuminate Support package.

630113.0M41.3k](/packages/illuminate-support)[shopware/platform

The Shopware e-commerce core

3.4k1.5M3](/packages/shopware-platform)[rubix/ml

A high-level machine learning and deep learning library for the PHP language.

2.2k1.5M28](/packages/rubix-ml)[illuminate/collections

The Illuminate Collections package.

27078.0M1.1k](/packages/illuminate-collections)

PHPackages © 2026

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