PHPackages                             ph-7/qrcode-generator-php-class - 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. ph-7/qrcode-generator-php-class

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

ph-7/qrcode-generator-php-class
===============================

Light QRCode PHP class (library). QR Code Generator using vCard 4.0 and the Google Chart AP

2.2.0(4y ago)10415.5k—0%54[2 issues](https://github.com/pH-7/QRCode-Generator-PHP-Class/issues)2GPL-3.0+PHPPHP &gt;=5.2.4

Since Jan 2Pushed 4y ago6 watchersCompare

[ Source](https://github.com/pH-7/QRCode-Generator-PHP-Class)[ Packagist](https://packagist.org/packages/ph-7/qrcode-generator-php-class)[ Docs](http://hizup.uk)[ RSS](/packages/ph-7-qrcode-generator-php-class/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (5)DependenciesVersions (6)Used By (2)

🚀 PHP QR Code 📱
===============

[](#-php-qr-code-)

[![Scrutinizer Quality Score](https://camo.githubusercontent.com/7b77c8684572450b5ee2491e255d0e0c0271a3b4d160148f4c69810b637d3385/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f70482d372f5152436f64652d47656e657261746f722d5048502d436c6173732f6261646765732f7175616c6974792d73636f72652e706e673f733d65343639613634613961633433613762343233336635383133613730373862303861356236393536)](https://scrutinizer-ci.com/g/pH-7/QRCode-Generator-PHP-Class/)

Description
-----------

[](#description)

**QRCode PHP class** allows you to easily generate a simple **QR code** using **vCard** 4.0 and the Google Chart API.

Here are two videos explaining QR code:  and

Composer Installation
---------------------

[](#composer-installation)

You can add it easily in your project by using [Composer](https://getcomposer.org/).

```
$ composer require ph-7/qrcode-generator-php-class
```

Then, include Composer's autoload

```
require_once 'vendor/autoload.php';
```

Manual Installation
-------------------

[](#manual-installation)

If you don't use Composer, you can install it without Composer by simply including the class

```
require 'QRCode.class.php';
```

How to Use
----------

[](#how-to-use)

Here's a basic example:

```
/**
 * If you have PHP 5.4 or higher, you can instantiate the object like this:
 * (new QRCode)->fullName('...')->... // Create vCard Object
 */
$oQRC = new QRCode; // Create vCard Object
$oQRC->fullName('Pierre-Henry Soria') // Add Full Name
    ->nickName('PH7') // Add Nickname
    ->gender('M') // Add Gender
    ->email('ph7software@gmail.com') // Add Email Address
    ->impp('phs_7@aol.com') // Add Instant Messenger
    ->url('http://ph-7.github.com') // Add URL Website
    ->note('Hello to all! I am a web developer. As hobbies I like climbing and swimming ...') // Add Note
    ->categories('developer,designer,climber,swimmer') // Add Categories
    ->photo('http://files.phpclasses.org/picture/user/1122955.jpg') // Add Avatar
    ->lang('en-US') // Add Language
    ->finish(); // End vCard

// echo ''; // Generate and display the QR Code
$oQRC->display(300); // Set size and display QR Code default 150px
```

You also have a sample file here:

Server Requirements
-------------------

[](#server-requirements)

PHP 5.2.4 or higher.

Author
------

[](#author)

[Pierre-Henry Soria](http://pierrehenry.be)

Contact
-------

[](#contact)

Contact me at: *pierrehenrysoria \[\[AT\]\] gmail \[\[D0T\]\] com*

License
-------

[](#license)

[General Public License 3](http://www.gnu.org/licenses/gpl.html) or later; See the LICENSE.txt file.

###  Health Score

40

—

FairBetter than 88% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity42

Moderate usage in the ecosystem

Community24

Small or concentrated contributor base

Maturity62

Established project with proven stability

 Bus Factor1

Top contributor holds 85% 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 ~411 days

Total

5

Last Release

1780d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/b6d95da236687f1dca4f7d70d60037c70ef217120ea195df23a39a412ba594e0?d=identicon)[ph-7](/maintainers/ph-7)

---

Top Contributors

[![pH-7](https://avatars.githubusercontent.com/u/1325411?v=4)](https://github.com/pH-7 "pH-7 (34 commits)")[![alitelli](https://avatars.githubusercontent.com/u/36549452?v=4)](https://github.com/alitelli "alitelli (3 commits)")[![lynxaegon](https://avatars.githubusercontent.com/u/1152748?v=4)](https://github.com/lynxaegon "lynxaegon (2 commits)")[![sergiobohrer](https://avatars.githubusercontent.com/u/3211075?v=4)](https://github.com/sergiobohrer "sergiobohrer (1 commits)")

---

Tags

generatorphpphp-qrphp-qrcodeqr-codeqrcodeqrcode-generatorqrcode-phpvcardqr codelibraryclassvCardqr code libraryqr code class

### Embed Badge

![Health badge](/badges/ph-7-qrcode-generator-php-class/health.svg)

```
[![Health](https://phpackages.com/badges/ph-7-qrcode-generator-php-class/health.svg)](https://phpackages.com/packages/ph-7-qrcode-generator-php-class)
```

###  Alternatives

[chillerlan/php-qrcode

A QR Code generator and reader with a user-friendly API. PHP 8.4+

2.4k28.9M208](/packages/chillerlan-php-qrcode)[nette/robot-loader

🍀 Nette RobotLoader: high performance and comfortable autoloader that will search and autoload classes within your application.

89352.7M321](/packages/nette-robot-loader)[league/iso3166

ISO 3166-1 PHP Library

70036.3M116](/packages/league-iso3166)[zxing/qr-reader

PHP qr code reader library

7542.7k1](/packages/zxing-qr-reader)[dekor/php-array-table

PHP Library for printing associative arrays as text table (similar to mysql terminal console)

296.6M2](/packages/dekor-php-array-table)

PHPackages © 2026

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