PHPackages                             trii/http-headers - 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. [HTTP &amp; Networking](/categories/http)
4. /
5. trii/http-headers

AbandonedLibrary[HTTP &amp; Networking](/categories/http)

trii/http-headers
=================

WTHeaders is a qvalue? Don't worry, we got that for you!

11111HTML

Since May 13Pushed 11y ago1 watchersCompare

[ Source](https://github.com/Trii/http-headers)[ Packagist](https://packagist.org/packages/trii/http-headers)[ RSS](/packages/trii-http-headers/feed)WikiDiscussions master Synced today

READMEChangelogDependenciesVersions (1)Used By (0)

http-headers - The HTTP Header parsing library for PHP
======================================================

[](#http-headers---the-http-header-parsing-library-for-php)

[![Build Status](https://camo.githubusercontent.com/496cbb0f71c5190a65263afcc08001b2fd32f896d9749a2db2fc3695f9b772ca/68747470733a2f2f7472617669732d63692e6f72672f547269692f687474702d686561646572732e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/Trii/http-headers)

`Accept: text/feedback, application/pull-requests`

SHOULD be interpreted as "*This is a work in progress. Early feedback and pull requests are accepted*"

HTTP is hard and you're probably dealing with headers the wrong way. Do you know what `Accept-Encoding: identity` means? What about a `qvalue`? How about this nonsense:

```
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8,application/json

```

We didn't think so but guess what? You don't have to! That is right, http-headers can parse this for you and just let you know if the requestor accepts what you want to give them and even ask which one they prefer.

Check out how easy this is!

```
use Trii\HTTPHeaders;

$accept = new HTTPHeaders\Accept('audio/*; q=0.2, audio/basic');

var_dump($accept->isAccepted('audio/mpeg'));
// bool(true)

var_dump($accept->getPreferredType());
// string(11) "audio/basic"
```

Awesome right?!?

###  Health Score

22

—

LowBetter than 21% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 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/75bc8cc6de5612589bd7951c2720ddba77c250e4ef2552707c66c7acb9d19371?d=identicon)[Trii](/maintainers/Trii)

---

Top Contributors

[![hello-josh](https://avatars.githubusercontent.com/u/638073?v=4)](https://github.com/hello-josh "hello-josh (9 commits)")

### Embed Badge

![Health badge](/badges/trii-http-headers/health.svg)

```
[![Health](https://phpackages.com/badges/trii-http-headers/health.svg)](https://phpackages.com/packages/trii-http-headers)
```

###  Alternatives

[php-http/cache-plugin

PSR-6 Cache plugin for HTTPlug

25126.1M82](/packages/php-http-cache-plugin)[illuminate/http

The Illuminate Http package.

11937.9M6.9k](/packages/illuminate-http)[rdkafka/rdkafka

A PHP extension for Kafka

2.2k24.3k1](/packages/rdkafka-rdkafka)[httpsoft/http-message

Strict and fast implementation of PSR-7 and PSR-17

87965.9k114](/packages/httpsoft-http-message)[mezzio/mezzio-router

Router subcomponent for Mezzio

265.4M92](/packages/mezzio-mezzio-router)[serpapi/google-search-results-php

Get Google, Bing, Baidu, Ebay, Yahoo, Yandex, Home depot, Naver, Apple, Duckduckgo, Youtube search results via SerpApi.com

69127.2k](/packages/serpapi-google-search-results-php)

PHPackages © 2026

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