rMQR Code Generator: Rectangular QR for Narrow Labels
Make an rMQR code, the rectangular QR code for shelf edges, cables and test tubes, and see how many characters fit at 7 modules high.
Contents
The price strip along a store shelf, a label wrapped around a cable, the side of a test tube or slim bottle, the edge of a circuit board. Try to put an ID number or URL on places like these as a 2D code, and a QR code runs out of height because it is square. There is plenty of room sideways, but only a few millimetres vertically. Shrink the code to fit and the modules get so small that it no longer scans.
The rMQR Code (Rectangular Micro QR Code) was designed for exactly these wide, short spaces. It is a rectangular 2D code developed by DENSO WAVE, the company that invented the QR code, and it was published as the international standard ISO/IEC 23941 in 2022 (DENSO WAVE’s rMQR Code page). The rMQR Code Generator turns the text or URL you enter into an rMQR Code and saves it as PNG or SVG. Everything happens inside your browser, and what you type is not sent anywhere.
Using the ID TL-2026-0153 as the example, this article first checks how much height rMQR saves compared with a QR code, then goes through choosing a size, how many characters fit at each height, and how to verify that the code scans.
For the same ID, the height including the quiet zone drops from 29 modules for a QR code to 11
Start by comparing the height of a QR code and an rMQR Code for the same ID. The unit is the module (sometimes called a cell): one of the small black or white squares the code is made of. If the module size is the same, the ratio of module counts is the ratio of the printed dimensions.
Making TL-2026-0153 (12 characters) with this site’s QR Code Generator at its default setting (error correction M) gives the smallest size, Version 1, at 21×21 modules. A QR code needs a quiet zone of 4 modules around it, so with the quiet zone it is 29×29 modules.
Entering the same ID into the rMQR Code Generator with the size set to “Auto” selected “R13x27”, 13 modules high and 27 wide. rMQR only needs a 2-module quiet zone, so including it the code is 17 modules high and 31 wide. Fixing the height to the lowest option, 7 modules, the ID fit in “R7x77”, 77 modules wide, which is a strip 11 modules high and 81 wide including the quiet zone. The image at the top shows these three at the same module size.
| Input string | QR code (with quiet zone) | rMQR Auto (with quiet zone) | rMQR 7 modules high (with quiet zone) |
|---|---|---|---|
TL-0001 (7 characters) |
21×21 (29×29) | R11x27 (15 high × 31 wide) | R7x59 (11 high × 63 wide) |
TL-2026-0153 (12 characters) |
21×21 (29×29) | R13x27 (17 high × 31 wide) | R7x77 (11 high × 81 wide) |
https://www.ixam.net/ (21 characters) |
25×25 (33×33) | R13x43 (17 high × 47 wide) | R7x77 (11 high × 81 wide) |
PN:RC0603-10K LOT:2611 (22 characters) |
25×25 (33×33) | R11x43 (15 high × 47 wide) | R7x77 (11 high × 81 wide) |
If you print each module at 0.25 mm, the QR code for TL-2026-0153 needs 7.25 mm square including the quiet zone. R7x77 needs only 2.75 mm of height, at the cost of about 20 mm of width. The area is about the same or even larger, but in a narrow space the first question is whether the height fits at all. It helps to think of rMQR not as a way to make a code smaller, but as a way to make its shape fit the space.
“Auto” picks R13x27 rather than R7x77 because this tool’s “Auto” chooses, among the sizes that can hold the input, the one with the smallest area (height × width in modules). R13x27 is 351 modules and R7x77 is 539, so R13x27 is smaller by area. When the label height is fixed, lock the size as described in the next section.
Lock the size to match the label height
From here we go through the tool step by step. The screenshots are from this English version.
1. Enter the ID
When you open the tool, the “Text or URL” box already contains https://www.ixam.net/, and the preview on the right shows its rMQR Code. Clear the box and type TL-2026-0153; the preview redraws automatically.
The line under the preview, “R13x27 / ECC M / 27 × 13 modules / 248 × 136 px / UTF-8 12 bytes”, describes the generated code. The size name “R13x27” is height × width, but the module and pixel counts after it are width × height. The 248 pixels are the 27 modules of width plus 2 quiet-zone modules on each side, 31 modules in total, times 8 pixels per module.
2. Choose the height under “Code size”
The “Code size (height × width)” list is grouped by the six heights: 7, 9, 11, 13, 15 and 17 modules. Decide the number of modules in height from the height available on the label, then pick the narrowest width in that group that holds your input. Here we pick “R7x77 (7 × 77)” in the 7-module group.
If the input does not fit in the selected size, the preview disappears and the message “The data does not fit in the selected size. Choose a larger size or “Auto”, or shorten the input.” appears. For example, TL-2026-0153 did not fit in “R7x43”, the narrowest 7-module size.
3. Adjust error correction, module size, quiet zone and colors, then save
Under “Error correction level” you can choose M (standard) or H (high). H is more resistant to dirt and damage, but holds much less data. Switching TL-2026-0153 to H, it no longer fit in R7x77, and “Auto” picked R11x43. Consider H for labels outdoors or where hands touch them, and allow for the larger size it needs.
“Module size (px)” is how many pixels each module is drawn with (2–20), and “Quiet zone (modules)” ranges from 2 to 20, with the standard 2 modules as the default. Keep the foreground dark and the background light. When the settings are done, use “Save as PNG” for screens and documents, or “Save as SVG” for label software, since SVG stays sharp when enlarged.
As with Data Matrix and QR codes, the printed size is “(modules + quiet zone × 2) × module size”. R7x77 with a 2-module quiet zone printed at 0.3 mm per module is 81 × 0.3 = 24.3 mm wide and 11 × 0.3 = 3.3 mm high. The same reasoning is covered in more detail in “How to make a QR code for flyers and business cards”.
How many characters fit at each height is mostly decided by the width
Once the label height has set the number of modules in height, the next question is how many characters of your data fit at that height. So I fixed the height and width in the tool and added one character at a time to see how many alphanumeric characters (ASCII) and how many CJK characters such as Japanese kanji would fit. Error correction is M.
| Height | 43 modules wide | 77 modules wide | 139 modules wide (max) |
|---|---|---|---|
| 7 modules | 5 alphanumeric / 1 CJK | 25 alphanumeric / 5 CJK | 60 alphanumeric / 13 CJK |
| 9 modules | 14 alphanumeric / 3 CJK | 41 alphanumeric / 9 CJK | 87 alphanumeric / 20 CJK |
| 11 modules | 24 alphanumeric / 5 CJK | 58 alphanumeric / 13 CJK | 118 alphanumeric / 27 CJK |
| 13 modules | 35 alphanumeric / 8 CJK | 73 alphanumeric / 16 CJK | 150 alphanumeric / 34 CJK |
| 15 modules | 44 alphanumeric / 10 CJK | 93 alphanumeric / 21 CJK | 180 alphanumeric / 41 CJK |
| 17 modules | 53 alphanumeric / 12 CJK | 109 alphanumeric / 25 CJK | 217 alphanumeric / 49 CJK |
Even at 7 modules high, stretching the width to 139 modules holds 60 alphanumeric characters. A short URL such as https://www.ixam.net/ fits in 7 × 77 modules. On the other hand, 7 × 43 modules holds only 5 alphanumeric characters, which is often not enough even for an ID. With error correction H the capacity drops to about half: even the largest size, R17x139, held 106 alphanumeric characters, and 7 × 139 modules held 31.
So that any language and even emoji decode correctly, this tool records every input as UTF-8 bytes and adds an ECI marker at the start indicating the character encoding. As a result, digits alone are treated the same as other alphanumeric characters, and capacity is lower than the theoretical maximum in the standard (for example, when packing digits only). Characters outside ASCII also take more bytes: accented Latin letters and Cyrillic take 2 bytes each in UTF-8, while CJK characters and Hangul take 3, so only a bit more than a third as many kanji fit as alphanumeric characters. For low labels, encode an alphanumeric ID or URL rather than a product name, and keep names and other details in a register or on the linked page.
Read the code back to verify it
rMQR is shaped differently from a QR code, so an app or device that reads QR codes will not read rMQR unless it supports it. A phone’s built-in camera does not necessarily support it, so before printing, check that the code scans in the environment where it will actually be used.
First, at the image stage, read the saved PNG with the rMQR Code Reader. Choose the PNG under “Image file”, and decoding starts right away, with the result shown under “Decoded text”.
The reader decodes with a different library (zxing-wasm) from the one the generator uses (bwip-js), so it is unlikely that both make the same mistake. For printed labels, hold them up to your phone or PC camera with the reader’s “Start camera”, or read them with the scanner you will use on site. Low codes are harder to focus on, so try a few angles and distances before you rely on them.
For a short ID alone, a rectangular Data Matrix can be smaller
Rectangular Data Matrix is another option for 2D codes in narrow places. As shown in “Labeling small tools and parts where a QR code won’t fit”, TL-2026-0153 as a rectangular Data Matrix is 32×8 modules, or 34×10 including the quiet zone. That is both lower and narrower than rMQR R7x77 (81×11 including the quiet zone). If all you need is to print a short ID small, Data Matrix has the edge.
There are still good reasons to choose rMQR:
- Your scanners or apps are built around QR codes and support rMQR. rMQR uses the same position-detection approach as QR codes, so it is easy to fit into a workflow that already assumes QR scanning.
- You want to fit longer data into a small height. The largest rectangular Data Matrix is 16 modules high and 48 wide, holding about 69 uppercase letters. rMQR can stay 7 modules high and stretch to 139 wide, and at 17 modules high it holds 217 alphanumeric characters.
- The label height is fixed but there is room sideways. rMQR lets you choose from six heights and adjust capacity through the width.
Either way, the final decision comes down to compatibility with the device that reads the code. The reliable approach is to make both, print test labels, and compare them on the actual hardware before deciding.
When you need many codes, or want to compare other shapes
If you need dozens of codes, as with shelf labels, put the list of IDs in a CSV and use Batch-generate rMQR Codes from CSV and print to PDF to skip saving and arranging them one by one. It creates rMQR Codes from the column you specify and lays them out on an A4 PDF.
Where a square is fine, there is the regular QR Code Generator, and for an even smaller square, the Micro QR Code Generator. Tools for creating and reading 2D codes are collected in the 2D Code Workspace.