PHPackages                             celema/session - 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. celema/session

ActiveLibrary

celema/session
==============

Celema session library

0.3.0(1mo ago)048[1 issues](https://github.com/celemas/session/issues)MITPHPPHP ^8.5CI passing

Since Jan 31Pushed 1w ago1 watchersCompare

[ Source](https://github.com/celemas/session)[ Packagist](https://packagist.org/packages/celema/session)[ Docs](https://celema.dev/session)[ RSS](/packages/celema-session/feed)WikiDiscussions main Synced 2w ago

READMEChangelogDependencies (2)Versions (4)Used By (0)

Celema Sessions
===============

[](#celema-sessions)

[![ci](https://camo.githubusercontent.com/fc8135f2695dbfc701585a9df7f13d92223b9250992ac2a5d301bf2945996176/68747470733a2f2f636f6465666c6f652e636f6d2f63656c656d612f73657373696f6e2f6261646765732f776f726b666c6f77732f63692e796d6c2f62616467652e7376673f7374796c653d666c6174266c6f676f3d666f7267656a6f266c6f676f436f6c6f723d7768697465266c6162656c3d6369)](https://codefloe.com/celema/session/actions)[![code coverage](https://camo.githubusercontent.com/846677fbafbb22f87ef1e1032e69b48755946c08a5b48bbdd4477b0dd61e281f/68747470733a2f2f696d672e736869656c64732e696f2f656e64706f696e743f75726c3d6874747073253341253246253246636f762e63656c656d612e64657625324663656c656d6125324673657373696f6e253246636f646525324662616467652e6a736f6e)](https://cov.celema.dev/celema/session/code)[![type coverage](https://camo.githubusercontent.com/8e7bb17bfc2d7de01cb7d4c630ee99c0d59ad4f96c4198593d16a907c7021d5d/68747470733a2f2f696d672e736869656c64732e696f2f656e64706f696e743f75726c3d6874747073253341253246253246636f762e63656c656d612e64657625324663656c656d6125324673657373696f6e253246747970657325324662616467652d636f7665722e6a736f6e)](https://cov.celema.dev/celema/session/types)[![psalm level](https://camo.githubusercontent.com/09918b9832659e21cf76a09694a63922aa041d628cf7ca54957b3e01b2d4b1ea/68747470733a2f2f696d672e736869656c64732e696f2f656e64706f696e743f75726c3d6874747073253341253246253246636f762e63656c656d612e64657625324663656c656d6125324673657373696f6e253246747970657325324662616467652d6c6576656c2e6a736f6e)](https://cov.celema.dev/celema/session/types)[![Software License](https://camo.githubusercontent.com/7013272bd27ece47364536a221edb554cd69683b68a46fc0ee96881174c4214c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d626c75652e737667)](LICENSE.md)

Helper classes for native PHP sessions, flash messages, and CSRF.

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

[](#installation)

```
composer require celema/session
```

Documentation
-------------

[](#documentation)

Start here: [docs/index.md](docs/index.md).

Quick start
-----------

[](#quick-start)

```
use Celema\Session\Session;

$session = new Session();
$session->start();

$session->set('user_id', 123);
$userId = $session->get('user_id');

$session->flash->add('Signed in.');

$token = $session->csrf->token('profile');
```

`Session` merges custom options with secure defaults for Secure and HttpOnly cookies, SameSite=Lax, strict session IDs, cookie-only session IDs, disabled transparent session IDs, and PHP's `nocache` session cache limiter. Set `cookie_secure` to `false` only for intentional plain HTTP environments, such as local development without TLS.

License
-------

[](#license)

This project is licensed under the [MIT license](LICENSE.md).

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance94

Actively maintained with recent releases

Popularity11

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity45

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

Every ~84 days

Total

3

Last Release

45d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/0c15f1690b643e5cbf205fd28f3b2ebb6c7448d34774bb92b7952150c901a689?d=identicon)[ernstla](/maintainers/ernstla)

---

Top Contributors

[![ernstla](https://avatars.githubusercontent.com/u/683620?v=4)](https://github.com/ernstla "ernstla (156 commits)")

---

Tags

sessions

### Embed Badge

![Health badge](/badges/celema-session/health.svg)

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

###  Alternatives

[tedivm/stash

The place to keep your cache.

9625.0M138](/packages/tedivm-stash)[aura/session

Provides session management functionality, including lazy session starting, session segments, next-request-only ("flash") values, and CSRF tools.

2061.3M80](/packages/aura-session)[geometria-lab/rediska

Full-featured PHP client for key-value database Redis

257317.7k1](/packages/geometria-lab-rediska)[rediska/rediska

Full-featured PHP client for key-value database Redis

261244.9k1](/packages/rediska-rediska)[tedivm/stash-bundle

Incorporates the Stash caching library into Symfony.

841.4M16](/packages/tedivm-stash-bundle)[cse/helpers-session

The helpers allows you to easily manage session data. START, SET, GET DELETE, HAS method session - all this is available in this library.

103.4k4](/packages/cse-helpers-session)

PHPackages © 2026

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