PHPackages                             awuxtron/websocket - 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. awuxtron/websocket

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

awuxtron/websocket
==================

The Websocket Client For PHP.

0.0.2(4y ago)09[2 PRs](https://github.com/awuxtron/websocket/pulls)MITPHPPHP ^8.1

Since May 28Pushed 2y ago1 watchersCompare

[ Source](https://github.com/awuxtron/websocket)[ Packagist](https://packagist.org/packages/awuxtron/websocket)[ Docs](https://github.com/awuxtron/websocket)[ GitHub Sponsors](https://github.com/awuxtron)[ RSS](/packages/awuxtron-websocket/feed)WikiDiscussions main Synced 3w ago

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

 **The Websocket Client For PHP.**
----------------------------------

[](#----the-websocket-client-for-php)

 [![License](https://camo.githubusercontent.com/70080a652d97c480a76f3a8758efb046e249d086bf3e6f7812787e6fadabf64b/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f6177757874726f6e2f776562736f636b65743f7374796c653d666c61742d737175617265)](https://github.com/awuxtron/websocket/blob/main/README.md) [![PHP Version Support](https://camo.githubusercontent.com/6f90fa92bbe4840833488dc59ab1c5bee81f7d6551806a4875df1d471da65e06/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f6177757874726f6e2f776562736f636b65743f7374796c653d666c61742d737175617265)](https://php.net) [![Packagist Version](https://camo.githubusercontent.com/da8e94e3190edfd670baaddb8a4c944b1fecc6e52203dd909dc12258f1d29b06/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6177757874726f6e2f776562736f636b65743f7374796c653d666c61742d737175617265)](https://packagist.org/packages/awuxtron/websocket) [![Packagist Downloads](https://camo.githubusercontent.com/cd0afb48498a4d6bc32ddeaf8b93546c5c4309f3f8b9602105b9030aa0c8878d/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6177757874726f6e2f776562736f636b65743f7374796c653d666c61742d737175617265)](https://packagist.org/packages/awuxtron/websocket) [![Code style fix status](https://camo.githubusercontent.com/2cf01529662e9a2bc12cfb22131902ed5a910cc7b20a5d7c4b86f739928358ec/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f776f726b666c6f772f7374617475732f6177757874726f6e2f776562736f636b65742f436865636b253230262532306669782532307374796c696e673f6c6162656c3d636f64652532307374796c65267374796c653d666c61742d737175617265)](https://github.com/awuxtron/websocket/actions/workflows/fix-code-style.yml) [![Code Static Analysis Status](https://camo.githubusercontent.com/ae4f316065e7526c207f4e2512e5fa14f9536cf265c01300f0a67261651e94ed/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f776f726b666c6f772f7374617475732f6177757874726f6e2f776562736f636b65742f436f6465253230537461746963253230416e616c797369733f6c6162656c3d616e616c797365267374796c653d666c61742d737175617265)](https://github.com/awuxtron/websocket/actions/workflows/analyse.yml) [![GitHub Workflow Status](https://camo.githubusercontent.com/61c271cb87dc876339a5b31c8f94ffbe91472120bf3e0a7581fec3c4ea98adb5/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f776f726b666c6f772f7374617475732f6177757874726f6e2f776562736f636b65742f54657374733f6c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/awuxtron/websocket/actions/workflows/run-tests.yml)

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

[](#installation)

You can install the package via composer:

```
composer require awuxtron/websocket
```

Usage
-----

[](#usage)

```
use Awuxtron\Websocket\Client;
use Awuxtron\Websocket\Enums\CloseStatus;

$client = new Client('ws://localhost:8080');
$socket = $client->connect();

$socket->send('hello');

echo $socket->read();

$socket->close(CloseStatus::NORMAL, 'Success');
```

Testing
-------

[](#testing)

```
composer test
```

Changelog
---------

[](#changelog)

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

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

[](#contributing)

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

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](../../security/policy) on how to report security vulnerabilities.

Credits
-------

[](#credits)

- [Awuxtron](https://github.com/awuxtron)
- [All Contributors](../../contributors)

License
-------

[](#license)

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

###  Health Score

23

—

LowBetter than 26% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~0 days

Total

2

Last Release

1496d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/96488794?v=4)[Diep Dang](/maintainers/awuxtron)[@awuxtron](https://github.com/awuxtron)

---

Top Contributors

[![awuxtron](https://avatars.githubusercontent.com/u/96488794?v=4)](https://github.com/awuxtron "awuxtron (14 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (8 commits)")[![github-actions[bot]](https://avatars.githubusercontent.com/in/15368?v=4)](https://github.com/github-actions[bot] "github-actions[bot] (8 commits)")

###  Code Quality

TestsPest

### Embed Badge

![Health badge](/badges/awuxtron-websocket/health.svg)

```
[![Health](https://phpackages.com/badges/awuxtron-websocket/health.svg)](https://phpackages.com/packages/awuxtron-websocket)
```

###  Alternatives

[aws/aws-sdk-php

AWS SDK for PHP - Use Amazon Web Services in your PHP project

6.3k543.5M2.6k](/packages/aws-aws-sdk-php)[spatie/crawler

Crawl all internal links found on a website

2.8k18.5M67](/packages/spatie-crawler)[laravel/reverb

Laravel Reverb provides a real-time WebSocket communication backend for Laravel applications.

1.6k15.1M84](/packages/laravel-reverb)[guzzlehttp/guzzle-services

Provides an implementation of the Guzzle Command library that uses Guzzle service descriptions to describe web services, serialize requests, and parse responses into easy to use model structures.

25711.0M191](/packages/guzzlehttp-guzzle-services)[onesignal/onesignal-php-api

A powerful way to send personalized messages at scale and build effective customer engagement strategies. Learn more at onesignal.com

34216.9k2](/packages/onesignal-onesignal-php-api)[eslazarev/wildberries-sdk

Wildberries OpenAPI clients (generated).

273.0k](/packages/eslazarev-wildberries-sdk)

PHPackages © 2026

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