PHPackages                             package-url/packageurl-php - 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. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. package-url/packageurl-php

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

package-url/packageurl-php
==========================

Builder and parser based on the package URL (purl) specification.

1.1.2(2y ago)142.0M↓13.6%6[4 issues](https://github.com/package-url/packageurl-php/issues)[5 PRs](https://github.com/package-url/packageurl-php/pulls)2MITPHPPHP ^7.3 || ^8.0CI passing

Since Apr 2Pushed 3w ago2 watchersCompare

[ Source](https://github.com/package-url/packageurl-php)[ Packagist](https://packagist.org/packages/package-url/packageurl-php)[ Docs](https://github.com/package-url/packageurl-php#readme)[ GitHub Sponsors](https://github.com/sponsors/jkowalleck)[ RSS](/packages/package-url-packageurl-php/feed)WikiDiscussions main Synced 1w ago

READMEChangelog (10)Dependencies (2)Versions (25)Used By (2)

Package URL (purl) for PHP
==========================

[](#package-url-purl-for-php)

[![shield_gh-workflow-test](https://camo.githubusercontent.com/e9fc60389ac051cda63b972894671571bb7dc96a93347a68cf1f2384ce7e2f40/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f7061636b6167652d75726c2f7061636b61676575726c2d7068702f7068702e796d6c3f6272616e63683d6d61696e263f6c6f676f3d476974487562266c6f676f436f6c6f723d7768697465 "build")](https://github.com/package-url/packageurl-php/actions?workflow=PHP+CI)[![shield_packagist-version](https://camo.githubusercontent.com/97da921c273db52ea303a48ff71f94ac87e1d2d6ff76fba506f27c5daf7cc426/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f7061636b6167652d75726c2f7061636b61676575726c2d7068703f6c6f676f3d266c6f676f436f6c6f723d7768697465 "packagist")](https://packagist.org/packages/package-url/packageurl-php)[![shield_license](https://camo.githubusercontent.com/0a1478ce0b15e066e3c246f34209ad6d21ba99624e6b444e25333ff6748528fa/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f7061636b6167652d75726c2f7061636b61676575726c2d706870 "license")](https://github.com/package-url/packageurl-php/blob/main/LICENSE)

---

A parser and builder based on [package url spec](https://github.com/package-url/purl-spec/blob/master/PURL-SPECIFICATION.rst), implemented in PHP.

License: MIT

Note

PackageURL (PURL) is currently undergoing a process of review and standardization, leading to updates in the specification.
As a result, this library may no longer comply with the latest PURL standards. It will not receive further updates until the standardization process is complete and a stable version of the specification is released. See [\#243](https://github.com/package-url/packageurl-php/issues/243)

Install
-------

[](#install)

```
composer require package-url/packageurl-php
```

Usage
-----

[](#usage)

see also [the examples](https://github.com/package-url/packageurl-php/tree/main/examples).

```
