# The best open-source QR code generators

> For libraries, the standouts are qrcode on npm (MIT), Python's qrcode and segno (BSD), ZXing (Apache 2.0, encode and decode), and Nayuki's QR Code generator, the respected multi-language reference implementation (MIT). For a finished hosted product that is itself open source, UseQR is MIT-licensed end to end. Judge every option by licence and maintenance activity.

Source: https://useqr.app/vs/best-open-source-qr-code-generator · Last reviewed 2026-08-21 · UseQR is free forever, MIT licensed, no signup.

---

## Two different questions hiding in one search

"Open-source QR generator" means either **a library** you embed in your own code, or
**a product** — a generator with a UI and API — whose source you can read, fork and
self-host. The lists are different and conflating them produces bad recommendations, so
here they are separately.

## The libraries

| Library | Language | Licence | Notes |
|---|---|---|---|
| qrcode (npm) | JavaScript | MIT | The default in the JS ecosystem; [detailed comparison](/vs/useqr-vs-qrcode-npm) |
| qr-code-styling | JavaScript | MIT | Styled codes — dots, eyes, logos; [comparison](/vs/useqr-vs-qr-code-styling) |
| qrcode (PyPI) | Python | BSD | The default in Python; [comparison](/vs/useqr-vs-python-qrcode) |
| segno | Python | BSD | Rigorous ISO/IEC 18004 coverage incl. Micro QR, zero dependencies |
| ZXing | Java (+ ports) | Apache 2.0 | Encodes **and decodes**; the decoder is the industry workhorse, now in maintenance mode |
| Nayuki QR Code generator | Java, TS, Python, Rust, C++, C | MIT | The respected reference implementation — small, correct, readable |

Two of these deserve a sentence more. **Nayuki's QR Code generator** is what you read
when you want to understand how encoding actually works — one careful codebase ported
across six languages, widely treated as a reference. **[ZXing](/glossary/zxing)** matters
because it decodes: any serious pipeline should read its codes back after generating
them, and ZXing (or a port) is usually the reader — it is what UseQR's own
[verify loop](/docs/developers/why-verify-that-your-qr-code-decodes) uses. The wider
field, including Go, Rust and PHP options, is surveyed in
[QR libraries compared](/docs/developers/qr-code-libraries-compared).

## The products

Most generator *websites* are closed — free to use, but you cannot read, audit or redeploy
them. The open exceptions are worth knowing:

- **UseQR** (MIT) — this site: generator UI, 28 payload builders written from the real
  specs, keyless API, MCP server, decode-verification. The
  [entire codebase is public](https://github.com/rajkaria/useqr), so "trust us" can be
  replaced with "read it". Disclosure: this is our page, which is exactly why the
  libraries above are listed first.
- **Library-plus-page builds** — many small open generators are a static page wrapping
  `qrcode` or `qr-code-styling`. Perfectly good; judge them individually by the criteria
  below.

If your interest in open source is really about running it yourself, that is its own
decision with its own trade-offs — covered in
[the self-hosted roundup](/vs/best-self-hosted-qr-code-generator) and the
[self-hosting guide](/docs/developers/self-hosting-a-qr-generator).

## How to judge any option

1. **Licence.** MIT/BSD/Apache mean unrestricted commercial embedding. Copyleft licences
   (GPL family) are fine for self-hosting but constrain embedding in proprietary code —
   check before you build on anything.
2. **Maintenance.** Look at the commit log, not the star count. A QR library can be
   legitimately "done" — the spec is from 2000 and stable — but a decoder or a product
   accumulating unfixed issues is a different signal.
3. **Correctness evidence.** Tests against the spec, and ideally decode-verification of
   output. Encoding bugs are silent; they produce codes that mostly scan.
4. **Payload scope.** Libraries encode strings; the WiFi/UPI/EPC payload formats on top
   are where [most real-world failures happen](/docs/troubleshooting/wifi-qr-code-not-connecting).
   Check whether the project handles them or leaves them to you.

## Honest bottom line

Inside your own codebase: use a library — qrcode, segno, or Nayuki depending on language
and taste, with ZXing reading the output back. For a finished product you can audit and
redeploy: UseQR is, to our knowledge, the most complete MIT-licensed option, and you can
[verify any of its output](/validate) independently rather than taking our word.

## FAQ

### What is the best open-source QR code library?
qrcode (npm) for JavaScript, qrcode or segno for Python, ZXing where you also need decoding, and Nayuki's QR Code generator as the reference implementation across six languages. All are permissively licensed.

### Is there a fully open-source QR code generator website?
Yes. UseQR is MIT-licensed end to end — UI, payload builders, API and verification — and can be self-hosted. Most other generator sites are closed products with free tiers rather than open source.

### Are open-source QR generators free for commercial use?
The permissively licensed ones (MIT, BSD, Apache 2.0) are, with obligations limited to attribution notices. Check the licence file on anything GPL-family before embedding it in proprietary software.

### Why does open source matter for QR codes?
Auditability and permanence. You can verify what happens to the data you encode, and if a hosted service disappears, an open codebase can be redeployed — printed static codes never depended on the service anyway.

## Try it

- https://useqr.app/url
- https://useqr.app/validate
