Encoding exact text into a QR matrix and a printable SVG file
A QR code represents text as a square pattern that compatible scanner apps can read. Enter a link, contact instruction or short message, then generate an SVG preview. Calculation Guide builds the QR matrix locally and leaves a white quiet zone around it. The tool does not visit the entered URL, verify its destination or shorten it.
A QR symbol has dark and light square modules. Encoding software chooses a version large enough for the input and its selected error-correction level. This page uses byte mode with UTF-8 input, automatic version selection and level M. DENSO WAVE describes error correction as a QR feature, but practical scan success also depends on code size, contrast, damage, lighting and the scanner. The generated SVG contains a four-module white border so modules are not pressed against nearby artwork.
The site generates the matrix and download entirely on the device, shows byte count and correction setting, and avoids an external image service that would receive the visitor's text.
How text length, characters and spacing change the QR code
The only input is the text, but every byte of it ends up in the pattern. Length, script and stray spaces all change the symbol.
- Text or link to encode
- The exact characters to store, read back exactly as entered. Capital letters, a trailing slash or tracking parameters each change the pattern and what the scanner shows, so paste the final link instead of retyping it. Leading and trailing spaces are kept as well: " https://example.com " is 21 bytes, not 19.
- 300-byte limit
- The cap counts UTF-8 bytes, not characters. Plain English letters and digits use one byte each, accented letters such as é and Urdu letters use two, the euro sign uses three and most emoji use four, so about 150 Urdu letters fill the limit. Text over the cap is rejected, never cut short.
- Content length and grid size
- Longer content needs a larger QR version with more modules per side. At level M, 14 bytes fit the smallest 21 × 21 grid, https://example.com at 19 bytes needs 25 × 25, an 84-byte link with tracking parameters needs 37 × 37, and 300 bytes needs 69 × 69. A denser grid needs a larger printed size to scan comfortably.
- Error correction level M
- Fixed at M, which DENSO WAVE describes as able to restore about 15% of the codewords. It cannot be changed here, so a code that will be partly covered by a logo or printed on a rough surface may need a generator that offers level Q or H.
- Quiet zone and SVG size
- The SVG adds a four-module white border on every side, so a 25-module code sits on a 33-unit square. Keep that border when placing the code on artwork, because text or graphics pressed against the modules can stop scanners locking on. The file is vector, so enlarge it in your layout rather than stretching a screenshot.
Steps
- Enter the exact text or link you want someone to scan; check spelling and punctuation before continuing.
- Select Generate QR code and inspect the rendered image. The content stays in your browser during encoding.
- Download the SVG if you need a vector image, then test the final printed or displayed size with the scanner and device you expect people to use.
Reading tip: Shorter content normally produces a simpler symbol. Use a direct, stable URL when the destination matters, and test a final export at its actual display or print size. An SVG is a vector file; you can resize it without turning its modules blurry, but an extremely small physical code can still be hard to scan.
Printing and sharing jobs a static QR code handles
Share a stable link
Encode a checked destination on a poster or card.
Make a short message scannable
Put a small text instruction into a square symbol.
Prepare print artwork
Download the vector SVG and check it at final physical size.
Test multilingual text
Encode UTF-8 content and verify it with the scanner people will use.
How the calculation works
- B
- Number of UTF-8 bytes in the visitor's exact text, including any spaces.
- M
- Selected QR error-correction level; the user does not set it in this version.
- module
- One square cell in the encoded QR matrix.
- +4
- Four-module light border on every side of the matrix.
These product settings describe the local encoder; an SVG preview is only rendered after the visitor requests it.
What every part means
- B
- Number of UTF-8 bytes in the visitor's exact text, including any spaces.
- M
- Selected QR error-correction level; the user does not set it in this version.
- module
- One square cell in the encoded QR matrix.
- +4
- Four-module light border on every side of the matrix.
Calculate it step by step
Unicode characters can use more than one byte. Calculation Guide's 300-byte cap is a usability and implementation choice.
The encoder selects a suitable standard version. This page does not report a fixed capacity for every possible input.
Four light modules on each side form the quiet zone; each dark module becomes a square SVG path.
The DENSO WAVE source explains QR error-correction levels; the open-source qrcode-generator package implements the QR matrix. Calculation Guide selects level M, UTF-8 byte input, automatic versioning, a 300-byte cap and four-module SVG margin as product choices. No remote QR API is involved. The code does not prove that a scanner app will trust a link or render every Unicode script the same way.
See how Calculation Guide tests examples and handles calculation limits.
See it in practice
- Text or link to encode
- https://example.com
The literal link https://example.com contains 19 UTF-8 bytes. On request, encode those bytes with level M, then draw the matrix with a four-module white border as an SVG.
- UTF-8 byte length19
- Error-correction settingM
Interpretation & limitations
How to read your result
The example link https://example.com is 19 UTF-8 bytes. A QR image for this literal string is generated after the visitor asks for it; the result card shows a crisp vector preview and an SVG download. Scanning the symbol yields the entered text, subject to the scanner's interpretation, and may offer to open that link. Generating the symbol itself does not connect to example.com.
Where this estimate stops
The generator does not host content, make a URL permanent, shorten links, monitor scans, track visitors, prove ownership or assess destination safety. Some older scanners may handle non-ASCII bytes differently. The image can become dense for longer text; test it in context. Avoid encoding secrets if the image will be public, because anyone who can scan it can read the content.
Frequently asked questions
01Is my text uploaded to a QR service?
No. Encoding and SVG creation happen locally in the browser when you request a result.
02Does this verify a link is safe?
No. The code contains the exact entered text; you remain responsible for checking any URL before sharing it.
03Why can the same tool produce different matrix sizes?
The encoder chooses a version that fits the number of bytes and the selected correction level; longer input may need more modules.
04Can I include Urdu or accented text?
The tool encodes UTF-8 bytes. Many modern scanners decode them as intended, but scanner interpretation can vary, so test the target device.
05Can I download a PNG?
This version offers SVG, a vector image that can be scaled for print or screen. It does not offer a PNG export.
06Can a QR code hide a harmful link?
Yes. The image does not certify safety. Review its original text and inspect any destination before opening it.
07Can I change where the code points after it is printed?
No. The text or link is stored in the pattern itself, so changing it means generating and printing a new code. If the destination may change, encode a stable address you control and update what that page shows or redirects to.