PHPackages                             lzqq/siwe - 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. lzqq/siwe

Active

lzqq/siwe
=========

00PHP

Pushed 9mo agoCompare

[ Source](https://github.com/longelyboy/siwe)[ Packagist](https://packagist.org/packages/lzqq/siwe)[ RSS](/packages/lzqq-siwe/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersionsUsed By (0)

Sign-In with Ethereum PHP
=========================

[](#sign-in-with-ethereum-php)

This package provides a PHP implementation of EIP-4361: Sign In With Ethereum.

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

[](#installation)

```
composer require lzqq/siwe
```

Usage
-----

[](#usage)

1. The wallet is connected to the client, then the wallet address is sent to the server
2. On the server we generate SIWE messages.

```
$params = new SiweMessageParams(
    address: $address,
    chainId: 1,
    domain: "example.com",
    uri: "https://example.com/path"
);
```

or with params builder:

```
$params = SiweMessageParamsBuilder::create()
            ->withAddress($address)
            ->withChainId(1)
            ->withDomain("example.com")
            ->withUri("https://example.com/path")->build();
```

And we generate the message text:

```
$message = SiweMessage::create($params);
```

3. On the client side, we sign the SIWE message via personal\_sign. We send the received signature to the server.
4. All that remains is to check the signature.

```
if (SiweMessage::verify($params, $signature)) {
    // authorization success
} else {
    // authorization failed (signature invalid)
}
```

You can also look at a fully working [example](example) of authorization using the library.

Links
-----

[](#links)

- [EIP-4361 Specification](https://eips.ethereum.org/EIPS/eip-4361).
- [Example of use](example)

###  Health Score

14

—

LowBetter than 2% of packages

Maintenance41

Moderate activity, may be stable

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity8

Early-stage or recently created project

 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/f8723bd8662626f5c0ba23bbfa9da55d7e743f3337ee9eebd8bc3a73baa3aa43?d=identicon)[longelyboy](/maintainers/longelyboy)

---

Top Contributors

[![longelyboy](https://avatars.githubusercontent.com/u/24969679?v=4)](https://github.com/longelyboy "longelyboy (3 commits)")

### Embed Badge

![Health badge](/badges/lzqq-siwe/health.svg)

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

PHPackages © 2026

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