PHPackages                             pollsockets/pollsockets-laravel - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. pollsockets/pollsockets-laravel

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

pollsockets/pollsockets-laravel
===============================

Serverside implementation of pollsockets taylored for Laravel

1.4.0(1mo ago)7161[3 PRs](https://github.com/pollsockets/pollsockets-laravel/pulls)MITPHPPHP ^8.2|^8.3|^8.4CI passing

Since Mar 31Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/pollsockets/pollsockets-laravel)[ Packagist](https://packagist.org/packages/pollsockets/pollsockets-laravel)[ Docs](https://github.com/pollsockets/pollsockets-laravel)[ RSS](/packages/pollsockets-pollsockets-laravel/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (4)Dependencies (28)Versions (9)Used By (0)

Serverside implementation of pollsockets tailored for Laravel
=============================================================

[](#serverside-implementation-of-pollsockets-tailored-for-laravel)

[![Latest Version on Packagist](https://camo.githubusercontent.com/081933c90a70d919d05616b67eca505af54c140f2f4201054349a69849680986/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f706f6c6c736f636b6574732f706f6c6c736f636b6574732d6c61726176656c2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/pollsockets/pollsockets-laravel)[![GitHub Tests Action Status](https://camo.githubusercontent.com/081d0c44eb03e3f5a3a8849d0d72e75134acd7fd2974891354ab1b424d723cc1/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f706f6c6c736f636b6574732f706f6c6c736f636b6574732d6c61726176656c2f72756e2d74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/pollsockets/pollsockets-laravel/actions?query=workflow%3Arun-tests+branch%3Amain)[![GitHub Code Style Action Status](https://camo.githubusercontent.com/03a5df1add8c966eeee4d26b577152387acf0951f6be2bbdba1ee013ac5fc6e2/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f706f6c6c736f636b6574732f706f6c6c736f636b6574732d6c61726176656c2f6669782d7068702d636f64652d7374796c652d6973737565732e796d6c3f6272616e63683d6d61696e266c6162656c3d636f64652532307374796c65267374796c653d666c61742d737175617265)](https://github.com/pollsockets/pollsockets-laravel/actions?query=workflow%3A%22Fix+PHP+code+style+issues%22+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/c48e0a74178545fcee06f80afaaf1f9566cbff914c019dc4028274116f82d75b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f706f6c6c736f636b6574732f706f6c6c736f636b6574732d6c61726176656c2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/pollsockets/pollsockets-laravel)

Why pollsockets?
----------------

[](#why-pollsockets)

Pollsockets is a simple, yet powerful, server-client communication library. It is designed to be used in situations where you need to send data from the server to the client. It is a great alternative to websockets, as it is much simpler to implement and use.

How does it work?
-----------------

[](#how-does-it-work)

Pollsockets uses a simple polling mechanism to send events from the server to the client. Instead of polling an endpoint that returns data, pollsockets polls an endpoint that returns a list of events that have occurred, thus saving bandwidth and response time. The client then processes the events and updates the UI accordingly.

Ecosystem
---------

[](#ecosystem)

### Server side

[](#server-side)

- [Laravel](https://github.com/pollsockets/pollsockets-laravel)

### Client side

[](#client-side)

- [Javascript](https://github.com/pollsockets/pollsockets-js)

Requirements
------------

[](#requirements)

- PHP 8.1 or higher
- Laravel 9.0 or higher
- Redis 6.0 or higher

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

[](#installation)

You can install the package via composer:

```
composer require pollsockets/pollsockets-laravel
```

You can publish the config file with:

```
php artisan vendor:publish --tag="pollsockets-config"
```

This is the contents of the published config file:

```
use Pollsockets\Drivers\RedisChannel;

return [
    'driver' => RedisChannel::class,
];
```

Usage
-----

[](#usage)

```
use Pollsockets\Pollsockets;

// Channel name can be any string. Can be used to separate events from different sources.
$channelName = 'channel';
// Event name can be any string. Can be used to separate events of the same type.
$event = 'reload';

// Publish an event to the channel from anywhere in your code. Perfect for informing client about changes in the database.
Pollsockets::channel($channelName)->publish($event);
```

Testing
-------

[](#testing)

```
composer test
```

Changelog
---------

[](#changelog)

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

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

[](#security-vulnerabilities)

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

Credits
-------

[](#credits)

- [Vytautas Smilingis](https://github.com/Plytas)
- [All Contributors](../../contributors)

License
-------

[](#license)

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

###  Health Score

49

—

FairBetter than 94% of packages

Maintenance90

Actively maintained with recent releases

Popularity17

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity68

Established project with proven stability

 Bus Factor1

Top contributor holds 56.3% 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

Every ~381 days

Total

4

Last Release

49d ago

PHP version history (2 changes)1.0.0PHP ^8.1

1.2PHP ^8.2|^8.3|^8.4

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/17316322?v=4)[Vytautas Smilingis](/maintainers/Plytas)[@Plytas](https://github.com/Plytas)

---

Top Contributors

[![Plytas](https://avatars.githubusercontent.com/u/17316322?v=4)](https://github.com/Plytas "Plytas (9 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (7 commits)")

---

Tags

laravelpollsocketspollsockets-laravel

###  Code Quality

TestsPest

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/pollsockets-pollsockets-laravel/health.svg)

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

###  Alternatives

[spatie/laravel-pdf

Create PDFs in Laravel apps

1.0k4.8M47](/packages/spatie-laravel-pdf)[codewithdennis/filament-select-tree

The multi-level select field enables you to make single selections from a predefined list of options that are organized into multiple levels or depths.

329530.5k29](/packages/codewithdennis-filament-select-tree)[rawilk/profile-filament-plugin

Profile &amp; MFA starter kit for filament.

3914.6k](/packages/rawilk-profile-filament-plugin)[worksome/exchange

Check Exchange Rates for any currency in Laravel.

124603.0k](/packages/worksome-exchange)[tarfin-labs/event-machine

Event-driven state machines for Laravel with event sourcing, type-safe context, and full audit trail.

199.4k](/packages/tarfin-labs-event-machine)

PHPackages © 2026

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