PHPackages                             hyqo/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. hyqo/http-headers

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

hyqo/http-headers
=================

1.0.0(3y ago)0271MITPHPPHP ^8.2

Since Mar 5Pushed 3y ago1 watchersCompare

[ Source](https://github.com/hyqo/http-headers)[ Packagist](https://packagist.org/packages/hyqo/http-headers)[ RSS](/packages/hyqo-http-headers/feed)WikiDiscussions main Synced 1mo ago

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

http-headers
============

[](#http-headers)

[![Packagist Version](https://camo.githubusercontent.com/6cdf61e572464f6fb1e1e5d863b7bcb102764837c0542d53d457507e79d4739c/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6879716f2f687474702d686561646572733f7374796c653d666c61742d737175617265)](https://camo.githubusercontent.com/6cdf61e572464f6fb1e1e5d863b7bcb102764837c0542d53d457507e79d4739c/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6879716f2f687474702d686561646572733f7374796c653d666c61742d737175617265)[![Packagist PHP Version Support](https://camo.githubusercontent.com/aafc389c89a4475e098bd33b74ec5fcfd23b084a8fd784894854f66c365be388/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f6879716f2f687474702d686561646572733f7374796c653d666c61742d737175617265)](https://camo.githubusercontent.com/aafc389c89a4475e098bd33b74ec5fcfd23b084a8fd784894854f66c365be388/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f6879716f2f687474702d686561646572733f7374796c653d666c61742d737175617265)[![GitHub Workflow Status](https://camo.githubusercontent.com/0569b89a143177db27b9d1ee4a791815a0532cb8fe548dece54aefebe3254cf1/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6879716f2f687474702d686561646572732f74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://camo.githubusercontent.com/0569b89a143177db27b9d1ee4a791815a0532cb8fe548dece54aefebe3254cf1/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f6879716f2f687474702d686561646572732f74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)

Install
-------

[](#install)

```
composer require hyqo/http-headers
```

Usage
-----

[](#usage)

### Forwarded ([MDN](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Forwarded))

[](#forwarded-mdn)

```
use Hyqo\Http\RequestHeaders;

$headers = new RequestHeaders(['Forwarded'=>'for=192.0.2.60; For="[2001:db8:cafe::17]:4711"; proto=https; host=foo.bar'])
$headers->forwarded->getFor(); //["192.0.2.60","[2001:db8:cafe::17]:4711"]
$headers->forwarded->getProto(); //"https"
$headers->forwarded->getHost(); //"foo.bar"
```

### X-Forwarded-For ([MDN](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-For))

[](#x-forwarded-for-mdn)

```
use Hyqo\Http\RequestHeaders;

$headers = new RequestHeaders(['X-Forwarded-For'=>'192.0.2.60, "[2001:db8:cafe::17]:4711"'])
$headers->forwarded->getFor()
```

```
array(2) {
[0]=>
string(10) "192.0.2.60"
[1]=>
string(24) "[2001:db8:cafe::17]:4711"
}

```

### X-Forwarded-Proto ([MDN](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-Proto))

[](#x-forwarded-proto-mdn)

```
use Hyqo\Http\RequestHeaders;

$headers = new RequestHeaders(['X-Forwarded-Proto'=>'https'])
$headers->forwarded->getProto()(); //https
```

### X-Forwarded-Prefix

[](#x-forwarded-prefix)

```
use Hyqo\Http\RequestHeaders;

$headers = new RequestHeaders(['X-Forwarded-Prefix'=>'/foo'])
$headers->forwarded->getPrefix(); //"/foo"
```

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity57

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.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

1161d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/e4230413a88525a7581fb391836718bcca27b8d1698f97b61de0dd6d816fac41?d=identicon)[akeylimepie](/maintainers/akeylimepie)

---

Top Contributors

[![akeylimepie](https://avatars.githubusercontent.com/u/355106?v=4)](https://github.com/akeylimepie "akeylimepie (2 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

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

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

###  Alternatives

[friendsofsymfony/rest-bundle

This Bundle provides various tools to rapidly develop RESTful API's with Symfony

2.8k73.3M317](/packages/friendsofsymfony-rest-bundle)[php-http/discovery

Finds and installs PSR-7, PSR-17, PSR-18 and HTTPlug implementations

1.3k309.5M1.2k](/packages/php-http-discovery)[nyholm/psr7

A fast PHP7 implementation of PSR-7

1.3k235.4M2.4k](/packages/nyholm-psr7)[pusher/pusher-php-server

Library for interacting with the Pusher REST API

1.5k94.8M292](/packages/pusher-pusher-php-server)[spatie/crawler

Crawl all internal links found on a website

2.8k16.3M52](/packages/spatie-crawler)[react/http

Event-driven, streaming HTTP client and server implementation for ReactPHP

78126.4M414](/packages/react-http)

PHPackages © 2026

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