PHPackages                             grupocoqueiro/escpos-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. grupocoqueiro/escpos-php

AbandonedLibrary

grupocoqueiro/escpos-php
========================

PHP receipt printer library for use with ESC/POS-compatible thermal and impact printers

v3.1.0(7y ago)0402MITPHPPHP &gt;=7.1

Since Jun 8Pushed 7y ago1 watchersCompare

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

READMEChangelog (3)Dependencies (3)Versions (38)Used By (0)

ESC/POS Print Driver for PHP
============================

[](#escpos-print-driver-for-php)

This project implements a subset of Epson's ESC/POS protocol for thermal receipt printers. It allows you to generate and print receipts with basic formatting, cutting, and barcodes on a compatible printer.

The library was developed to add drop-in support for receipt printing to any PHP app, including web-based point-of-sale (POS) applications.

Compatibility
-------------

[](#compatibility)

### Interfaces and operating systems

[](#interfaces-and-operating-systems)

This driver is known to work with the following OS/interface combinations:

 LinuxMacWindowsEthernet[Yes](https://github.com/mike42/escpos-php/tree/master/example/interface/ethernet.php)[Yes](https://github.com/mike42/escpos-php/tree/master/example/interface/ethernet.php)[Yes](https://github.com/mike42/escpos-php/tree/master/example/interface/ethernet.php)USB[Yes](https://github.com/mike42/escpos-php/tree/master/example/interface/linux-usb.php)Not tested[Yes](https://github.com/mike42/escpos-php/tree/master/example/interface/windows-usb.php)USB-serialYesYesYesSerialYesYesYesParallel[Yes](https://github.com/mike42/escpos-php/tree/master/example/interface/windows-lpt.php)Not testedYesSMB shared[Yes](https://github.com/mike42/escpos-php/tree/master/example/interface/smb.php)No[Yes](https://github.com/mike42/escpos-php/tree/master/example/interface/smb.php)CUPS hosted[Yes](https://github.com/mike42/escpos-php/tree/master/example/interface/cups.php)[Yes](https://github.com/mike42/escpos-php/tree/master/example/interface/cups.php)No### Printers

[](#printers)

Many thermal receipt printers support ESC/POS to some degree. This driver has been known to work with:

- Bematech-4200-TH

Basic usage
-----------

[](#basic-usage)

### Include the library

[](#include-the-library)

#### Composer

[](#composer)

If you are using composer, then add `grupocoqueiro/escpos-php` as a dependency:

```
composer require grupocoqueiro/escpos-php
```

In this case, you would include composer's auto-loader at the top of your source files:

```
