Get Access to Printers From Web Application

Let’s say we’re developing web-based POS system, where receipts needs be printed on the special kind of printer, but we don’t want user to deal with printer confirmation dialog, which will appear each time receipt need be printed due to the nature of web browsers.

Things will get even more complicated when we find that POS workplaces has to be equipped with tablets instead of normal PCs

How could we eliminate those issues?

That’s where cloud printing comes to the rescue by enabling communication with printers via HTTP requests, just like we normally do with third party services.

In this post I’m going to briefly cover few cloud print solutions that we can use in our web application straight away.

Google Cloud Print

Enables any app (web, desktop, mobile) on any device to print to any printer.

From the point of developer Google Cloud Print looks more like a platform which not only allows to access any printers to web application, but also implement cloud ready printers to make users life even easier.

Standard printers can also be accessed by web applications, but in this case user has to run Chrome web browser or cloud print connector service on the computer with an access to desired printer. The following help page describes how to connect classic printers:


Remote Printing For Web Apps

Technically it is similar to the Google Cloud Print, user have to install special client applications on the computer which has an access to the printers. At the moment of writing the client application has been available for MAC and Windows only.

One special thing about PrintNode is that in addition to printers it also supports Scalers, which we might consider for our web-based POS system.

Also, it is paid service.

Printer Express

Share standard printers via JSON API

It comes as a tiny web server running on the server or PC which has an access to printers, so, when web application accessed from the same network it can easily send requests directly to the printer express service, e.g. XHR.

Also, it is open source, so, can be adopted to a number of use cases, for example it can be deployed on a Raspberry PI, enabling constant access to receipt printer for our web-based POS.