# HTTPlug

> HTTP client abstraction and plugins for PHP

Source: https://talira.ai/catalog/httplug-36wnz3f1
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Library
- Categories: [libraries / http clients](https://talira.ai/categories/libraries/http-clients), [languages / php](https://talira.ai/categories/languages/php)
- Licence: MIT[^3][^4]
- Pricing: Free and open source[^2]
- Free tier: yes[^2]
- Supports: [PSR-7](https://talira.ai/standards/psr-7.md)[^1], [PSR-17](https://talira.ai/standards/psr-17.md)[^5], [PSR-18](https://talira.ai/standards/psr-18.md)[^1]
- Backed by: [PHP-HTTP](https://talira.ai/orgs/php-http.md)

HTTPlug, from the PHP-HTTP project, is an HTTP client abstraction for PHP built on PSR-7 messages. It defines an asynchronous HTTP client interface, plus a synchronous one with the same signature as PSR-18, so a library can depend on the interface instead of a concrete client. Around it, PHP-HTTP ships clients (socket, cURL), adapters for other clients such as [Guzzle](https://talira.ai/catalog/guzzle-2h73yn9k.md), an implementation-independent plugin system for authentication, cookies and more, and php-http/discovery, which finds and installs well-known PSR-17, PSR-18 and HTTPlug implementations.

## Links

- Website: https://php-http.org/
- GitHub: https://github.com/php-http/httplug
- Docs: https://docs.php-http.org/

## Problems it solves

- let my PHP SDK work with whatever HTTP client the user already has
- find an installed PSR-18 HTTP client automatically in a PHP library
- send asynchronous HTTP requests in PHP without tying to one client

## Features

- asynchronous HTTP client interface with promises
- synchronous client interface matching PSR-18
- discovery and auto-installation of PSR-17, PSR-18 and HTTPlug implementations
- client-independent plugins for authentication, cookies and more
- clients for sockets and cURL, and adapters for Guzzle and others

## Limitations

- For synchronous requests its makers recommend using PSR-18 directly rather than HTTPlug.[^1]

## Trust

Overall: 0.50 out of 1.
Signals: maintenance 0.65, adoption 0.68, momentum 0.39, community 0.51, backing 0.30, extensibility 0.00.

- last commit 8 days ago
- 7 commits in the last 90 days
- latest release 2.4.1 2.2 years ago
- 2.6k GitHub stars
- 18 contributors
- backed by PHP-HTTP

## Alternatives

- [Guzzle](https://talira.ai/catalog/guzzle-2h73yn9k.md): PHP HTTP client
- [Buzz (PHP HTTP client)](https://talira.ai/catalog/buzz-php-http-client-gksmeft0.md): PHP's lightweight HTTP client
- [PHP Curl Class](https://talira.ai/catalog/php-curl-class-rnvw0hmr.md): Object-oriented wrapper around PHP's cURL extension for HTTP requests

## Sources

[^1]: https://github.com/php-http/httplug/blob/master/README.md (checked 28 Nov 2026)
[^2]: https://docs.php-http.org/en/latest/ (checked 28 Nov 2026)
[^3]: https://github.com/php-http/httplug/blob/master/LICENSE (checked 28 Nov 2026)
[^4]: https://github.com/php-http/discovery/blob/1.x/LICENSE (checked 28 Nov 2026)
[^5]: https://github.com/php-http/discovery/blob/1.x/README.md (checked 28 Nov 2026)
