PHPackages                             avlima/php-cpf-cnpj-generator - 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. avlima/php-cpf-cnpj-generator

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

avlima/php-cpf-cnpj-generator
=============================

Brazilian document generator

1.0.0(4y ago)210.6k↓21.4%MITPHPPHP &gt;=7.1

Since Jan 13Pushed 4y ago1 watchersCompare

[ Source](https://github.com/avlima/php-cpf-cnpj-generator)[ Packagist](https://packagist.org/packages/avlima/php-cpf-cnpj-generator)[ Docs](https://github.com/avlima/php-cpf-cnpj-generator)[ RSS](/packages/avlima-php-cpf-cnpj-generator/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (2)Used By (0)

[![Packagist](https://camo.githubusercontent.com/7445dfc6dfe2456188de337a184c313524809ada9e54c37119e8092513c09694/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f61766c696d612f7068702d6370662d636e706a2d67656e657261746f722e7376673f7374796c653d666c6174)](https://packagist.org/packages/avlima/php-cpf-cnpj-generator)[![PHP from Packagist](https://camo.githubusercontent.com/755ae59d7b508c59e6aa5a18794d0feea5c5936a8cb44a48572945f67f2531bc/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f61766c696d612f7068702d6370662d636e706a2d67656e657261746f722e7376673f6c6f676f3d706870266c6f676f436f6c6f723d7768697465267374796c653d666c6174)](https://packagist.org/packages/avlima/php-cpf-cnpj-generator)[![GitHub license](https://camo.githubusercontent.com/f48f8d6cf609f5b181b9c3218a85175fe8a5809c7ea400347f39697a5d55065d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d626c75652e7376673f7374796c653d666c6174)](https://raw.githubusercontent.com/avlima/php-cpf-cnpj-generator/master/LICENSE)[![Total Downloads](https://camo.githubusercontent.com/9b61110024419c076e629dfac8a2caa5495683e8c241cb4a8f6011b38541065c/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f61766c696d612f7068702d6370662d636e706a2d67656e657261746f722e7376673f7374796c653d666c6174)](https://packagist.org/packages/avlima/php-cpf-cnpj-generator)

Brazilian document generator for PHP
====================================

[](#brazilian-document-generator-for-php)

#### [Star ⭐](https://github.com/avlima/php-cpf-cnpj-generator) repo to show suport 😊

[](#star--repo-to-show-suport-)

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

[](#installation)

### Install Package

[](#install-package)

Require this package with composer:

```
composer require avlima/php-cpf-cnpj-generator

```

Usage
-----

[](#usage)

Add the class `use Avlima\PhpCpfCnpjGenerator\Generator;` to your file:

```
Generator::cpf();
- output: 84255523037

Generator::cpf(true);
- output: 842.555.230-37

Generator::cnpj();
- output: 14905492000179

Generator::cnpj(true);
- output: 14.905.492/0001-79

```

Thanks
------

[](#thanks)

```
## Support
Feel free to post your issues in the issues section.

## Credits
Developed by [Alberto Lima](https://github.com/avlima "Alberto Vieira de Lima")

## License
MIT

```

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity27

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity44

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

Unknown

Total

1

Last Release

1586d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8912db2ced555e1efb149ba4b510e78f5a30d9be0c006bfd132b84426fbbfff9?d=identicon)[avlima](/maintainers/avlima)

---

Top Contributors

[![avlima](https://avatars.githubusercontent.com/u/13434925?v=4)](https://github.com/avlima "avlima (7 commits)")

---

Tags

laravel mmenvioCpf generatorCnpj generatorFake cpfFake cnpjCreate cpfCreate cnpjBrazilian document

### Embed Badge

![Health badge](/badges/avlima-php-cpf-cnpj-generator/health.svg)

```
[![Health](https://phpackages.com/badges/avlima-php-cpf-cnpj-generator/health.svg)](https://phpackages.com/packages/avlima-php-cpf-cnpj-generator)
```

###  Alternatives

[scws/pscws4

PSCWS 是英文 PHP Simple Chinese Words Segmentation 的头字母缩写，它是 SCWS 项目的前身。

1213.2k1](/packages/scws-pscws4)

PHPackages © 2026

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