PHPackages                             lidelin/erc20-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. [API Development](/categories/api)
4. /
5. lidelin/erc20-php

ActiveLibrary[API Development](/categories/api)

lidelin/erc20-php
=================

Interact with any ERC20 standard Ethereum token

0.1.2(7y ago)16MITPHPPHP &gt;=7.1.0

Since May 9Pushed 7y ago1 watchersCompare

[ Source](https://github.com/lidelin/erc20-php)[ Packagist](https://packagist.org/packages/lidelin/erc20-php)[ RSS](/packages/lidelin-erc20-php/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (1)Dependencies (1)Versions (4)Used By (0)

forked from [furqansiddiqui/erc20-php](https://github.com/furqansiddiqui/erc20-php)

ERC20 Tokens
============

[](#erc20-tokens)

Interact with any ERC20 standard Ethereum token

This package is ultimate response to historic issue of no native API being available to PHP developers to interact with ERC20 tokens (i.e. web3js contracts API).

This package communicates directly with `Geth` using `RPC` ([lidelin/ethereum-rpc](https://github.com/lidelin/ethereum-rpc/)) and performs all `ABI` encoding and decoding in background, resulting in pure simple and easy to use API for developers to perform all ERC20 standard operations.

Demo
----

[](#demo)

- A random ERC20 token was picked from a list, given contract address `0xd26114cd6EE289AccF82350c8d8487fedB8A0C07`

```
$geth = new EthereumRPC('127.0.0.1', 8545);
$erc20 = new \ERC20\ERC20($geth);
$token = $erc20->token('0xd26114cd6EE289AccF82350c8d8487fedB8A0C07');

var_dump($token->name());
var_dump($token->symbol());
var_dump($token->decimals());
```

Result:

```
string(8) "OMGToken"
string(3) "OMG"
int(18)

```

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

[](#installation)

`composer require lidelin/erc20-php`

### Prerequisites

[](#prerequisites)

- **PHP** &gt;= 7.1+
- **Ethereum RPC client** ([lidelin/ethereum-rpc](https://github.com/lidelin/ethereum-rpc/)) &gt;= 0.1.2

ABI
---

[](#abi)

A standard ERC20 ABI file is included in package residing in "data" directory.

Path to a custom ABI may be specified when constructing ERC20 token object.

```
$geth = new EthereumRPC('127.0.0.1', 8545);
$erc20 = new \ERC20\ERC20($geth);
$erc20->abiPath('/path/to/abi.json');
```

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity50

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

Total

3

Last Release

2858d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4dba5992f96265f605d24b5c1a763ad728e83f0d3595bd1492c58b747450996c?d=identicon)[lidelin](/maintainers/lidelin)

---

Top Contributors

[![furqansiddiqui](https://avatars.githubusercontent.com/u/11485189?v=4)](https://github.com/furqansiddiqui "furqansiddiqui (14 commits)")

---

Tags

tokenstokenethereumethgethethereum-goerc20

### Embed Badge

![Health badge](/badges/lidelin-erc20-php/health.svg)

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

###  Alternatives

[furqansiddiqui/erc20-php

Interact with any ERC20 standard/backward-compatible Ethereum token

16466.3k4](/packages/furqansiddiqui-erc20-php)[furqansiddiqui/ethereum-rpc

Ethereum (geth) RPC client

2550.6k4](/packages/furqansiddiqui-ethereum-rpc)[drlecks/simple-web3-php

Web3 library in PHP

7641.6k2](/packages/drlecks-simple-web3-php)

PHPackages © 2026

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