PHPackages                             rnaga/emit-php - 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. [Framework](/categories/framework)
4. /
5. rnaga/emit-php

ActiveLibrary[Framework](/categories/framework)

rnaga/emit-php
==============

A PHP framework to develop WebSocket, HTTP and FCGI Applications

9103[1 issues](https://github.com/rnaga/EmitPHP/issues)PHP

Since Mar 23Pushed 9y ago2 watchersCompare

[ Source](https://github.com/rnaga/EmitPHP)[ Packagist](https://packagist.org/packages/rnaga/emit-php)[ RSS](/packages/rnaga-emit-php/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

EmitPHP
=======

[](#emitphp)

EmitPHP is a PHP framework that works with non-blocking I/O.

You can write your web applications and APIs in HTTP, FCGI and WebSocket.

As of now, this is an experimental project and there still exists errors and bugs.

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

[](#installation)

- It requires PHP 7(CLI) and composer to run
- If you haven't installed composer, run below to install it.

```
curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer
```

- Download [EmitPHP source code](https://github.com/rnaga/EmitPHP.git) from github
- Run composer to create autoload

```
composer install
```

Now you can run [Examples](https://github.com/rnaga/EmitPHP/tree/master/examples)

Usage
-----

[](#usage)

### WebSocket

[](#websocket)

Yes, EmitPHP supports WebSocket.

you can create your WebSocket Application with a few lines of code.

Below is an example of how to create a WebSocket Application.

```
// Create a new WS Application
$app = (new WSServer())->listen(4000)->app();
// Triggers when messages received
$app->on('message', function($conn, $msg){
    // Echo message
    $conn->send("echo => ". $msg);
    // Close the connection
    $conn->close();
});

\Emit\Loop();
```

### HTTP

[](#http)

You can easily create a HTTP server as below

```
$server = (new HTTPServer())->listen(4000);
$server->on('request', function($req, $res){
    // Send response
    $res->send("Hello World");
    // Close connection
    $res->end();
});

\Emit\Loop();
```

### Router

[](#router)

Example for using Router

```
$server = (new HTTPServer())->listen(9000);
// Create a new Route
$route = $server->route();
// Get method
$route->get("/", function($req, $res, $next){
    $res->send("Hello World");
    // Calling the next handler
    $next();
});
// Register the route
$server->use($route);

\Emit\Loop();
```

### FCGI

[](#fcgi)

EmitPHP supports FCGI which works with Web Servers such as apache

```
$server = (new FCGIServer())->listen(9000);
$server->on('request', function($req, $res){
    // Send response
    $res->send("Hello World");
    // Close connection
    $res->end();
});

\Emit\Loop();
```

See [examples](https://github.com/rnaga/EmitPHP/tree/master/examples) for more details.

What's next
-----------

[](#whats-next)

Please send me your feeback at  and let me know how you like it. If there are demands, I will work more.

And if any of you wants to join the project, please let me know.

License
-------

[](#license)

EmitPHP is licensed under the MIT license. See License File for more information.

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance18

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 90.9% 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/43130b57f015bad477e6043bcca6756524aede700be97fa23cbb824c9e6d4def?d=identicon)[rnaga](/maintainers/rnaga)

---

Top Contributors

[![rnaga](https://avatars.githubusercontent.com/u/20383976?v=4)](https://github.com/rnaga "rnaga (10 commits)")[![luwake](https://avatars.githubusercontent.com/u/11704776?v=4)](https://github.com/luwake "luwake (1 commits)")

### Embed Badge

![Health badge](/badges/rnaga-emit-php/health.svg)

```
[![Health](https://phpackages.com/badges/rnaga-emit-php/health.svg)](https://phpackages.com/packages/rnaga-emit-php)
```

###  Alternatives

[laravel/telescope

An elegant debug assistant for the Laravel framework.

5.2k67.8M190](/packages/laravel-telescope)[spiral/roadrunner

RoadRunner: High-performance PHP application server and process manager written in Go and powered with plugins

8.4k12.2M84](/packages/spiral-roadrunner)[nolimits4web/swiper

Most modern mobile touch slider and framework with hardware accelerated transitions

41.8k177.2k1](/packages/nolimits4web-swiper)[laravel/dusk

Laravel Dusk provides simple end-to-end testing and browser automation.

1.9k36.7M255](/packages/laravel-dusk)[laravel/prompts

Add beautiful and user-friendly forms to your command-line applications.

708181.8M591](/packages/laravel-prompts)[cakephp/chronos

A simple API extension for DateTime.

1.4k47.7M119](/packages/cakephp-chronos)

PHPackages © 2026

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