PHPackages                             ahinkle/packagist-latest-version - 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. ahinkle/packagist-latest-version

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

ahinkle/packagist-latest-version
================================

Obtains the latest version release of Composer Packages from the Packagist API

2.1.0(3y ago)31.8k12MITPHPPHP ^8.0

Since Mar 19Pushed 3y ago1 watchersCompare

[ Source](https://github.com/ahinkle/packagist-latest-version)[ Packagist](https://packagist.org/packages/ahinkle/packagist-latest-version)[ Docs](https://github.com/ahinkle/packagist-latest-version)[ RSS](/packages/ahinkle-packagist-latest-version/feed)WikiDiscussions master Synced 3w ago

READMEChangelog (4)Dependencies (2)Versions (5)Used By (2)

 [![](https://camo.githubusercontent.com/6089caade245e8d8e3998f9b626f5e169f542ba583c034f0cc1f585a5f5c6eb5/68747470733a2f2f7061636b61676973742e6f72672f62756e646c65732f7061636b61676973747765622f696d672f6c6f676f2d736d616c6c2e706e673f763d31353834303238333233)](https://camo.githubusercontent.com/6089caade245e8d8e3998f9b626f5e169f542ba583c034f0cc1f585a5f5c6eb5/68747470733a2f2f7061636b61676973742e6f72672f62756e646c65732f7061636b61676973747765622f696d672f6c6f676f2d736d616c6c2e706e673f763d31353834303238333233)

[![Build Status](https://github.com/ahinkle/packagist-latest-version/workflows/tests/badge.svg)](https://github.com/ahinkle/packagist-latest-version/actions)[![Latest Stable Version](https://camo.githubusercontent.com/9ffabbfc4d936dda09a8352b1fd7a1bbc4c391dca58bbb7d150377ee8740ce4b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6168696e6b6c652f7061636b61676973742d6c61746573742d76657273696f6e2e7376673f7374796c653d666c6174)](https://packagist.org/packages/ahinkle/packagist-latest-version)[![Style CI](https://camo.githubusercontent.com/69742b436596c4cfc1742f4610577dc761155ab04c633af322efd16d828eae2a/68747470733a2f2f7374796c6563692e696f2f7265706f732f3234383235393739372f736869656c643f6272616e63683d6d6173746572)](https://packagist.org/packages/ahinkle/packagist-latest-version)[![Total Downloads](https://camo.githubusercontent.com/d46597f7c4a1f9cc3c44ad7fef22543d5d41209cb8ec8b2578f7afb7d7ae5a5a/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6168696e6b6c652f7061636b61676973742d6c61746573742d76657273696f6e2e7376673f7374796c653d666c6174)](https://packagist.org/packages/ahinkle/packagist-latest-version)[![License](https://camo.githubusercontent.com/1a2e0606685ce00663bf829868f794fd3fc9c86f8d80cae324734129e0723a58/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d627269676874677265656e2e737667)](https://packagist.org/packages/ahinkle/packagist-latest-version)

Composer Packagist Latest Version
=================================

[](#composer-packagist-latest-version)

This package provides an easy way to retrieve the latest stable release from composer packages via [the Packagist API](https://packagist.org/apidoc). This package was inspired by [this tweet](https://twitter.com/seldaek/status/1240285841492148225) after discovering that it's not possible to retrieve the latest non-development tagged release.

This package will return the *highest* tagged non-developmental release. e.g. When there is a 2.1.0 release then a new 1.2.1 release is posted, this will continue to show that 2.1.0 is still the latest version.

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

[](#installation)

You can install the package via composer:

```
composer require ahinkle/packagist-latest-version
```

Usage
-----

[](#usage)

```
$client = new \GuzzleHttp\Client();

$packagist = new PackagistLatestVersion($client);

$packagist->getLatestRelease('laravel/framework');
```

### Testing

[](#testing)

```
composer test
```

### Changelog

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

### Security

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Andy Hinkle](https://github.com/ahinkle)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

33

—

LowBetter than 72% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity21

Limited adoption so far

Community16

Small or concentrated contributor base

Maturity64

Established project with proven stability

 Bus Factor1

Top contributor holds 52.4% 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.

###  Release Activity

Cadence

Every ~331 days

Total

4

Last Release

1294d ago

Major Versions

1.0.1 → 2.0.02021-12-22

PHP version history (2 changes)1.0.0PHP ^7.2

2.0.0PHP ^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/7b5558f0a50bd4e108a9b1e010f8b173a3992b14220e6a34c03d8bea90d1dde3?d=identicon)[ahinkle](/maintainers/ahinkle)

---

Top Contributors

[![ahinkle](https://avatars.githubusercontent.com/u/17038330?v=4)](https://github.com/ahinkle "ahinkle (11 commits)")[![DaltonMcCleery](https://avatars.githubusercontent.com/u/37309201?v=4)](https://github.com/DaltonMcCleery "DaltonMcCleery (9 commits)")[![AydinHassan](https://avatars.githubusercontent.com/u/2817002?v=4)](https://github.com/AydinHassan "AydinHassan (1 commits)")

---

Tags

composerpackagistpackagist-apiphpcomposerversionlatestpackagistahinklepackagist apipackagist-latest-version

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/ahinkle-packagist-latest-version/health.svg)

```
[![Health](https://phpackages.com/badges/ahinkle-packagist-latest-version/health.svg)](https://phpackages.com/packages/ahinkle-packagist-latest-version)
```

###  Alternatives

[playbloom/satisfy

Satis composer repository manager with a Web UI

54710.6k](/packages/playbloom-satisfy)[badges/poser

Poser, add badges on your readme..

14476.9k11](/packages/badges-poser)[cybercog/laravel-paket

Composer personal web interface. Manage Laravel dependencies without switching to command line!

1763.3k](/packages/cybercog-laravel-paket)[jelix/version

Parse any version syntax, including semantic version. Compare version, using Composer version constraints syntax.

13205.7k5](/packages/jelix-version)[linkorb/autotune

Tune your autoloader

177.3k17](/packages/linkorb-autotune)

PHPackages © 2026

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