How a QR code is built
QR Code is a two-dimensional barcode standardized as ISO/IEC 18004. To encode your text, the generator converts it to UTF-8 bytes and writes them in byte mode; picks the smallest version (1 through 40) that fits the data at the chosen error correction level; computes Reed-Solomon error correction codewords over GF(256) and interleaves them with the data; places the three finder patterns, alignment patterns, timing patterns and format information on the grid; fills in the data in a zigzag; and finally tests all 8 mask patterns and keeps the one with the lowest penalty score, which avoids large blobs of one color and shapes that could be mistaken for a finder pattern. All of that runs in plain JavaScript in your browser - no library, no server, no tracking.
Version 1 is 21 x 21 modules and each version adds 4 modules per side, up to 177 x 177 at version 40. In byte mode version 1 holds 17 bytes at level L (14 at M, 11 at Q, 7 at H); version 40 holds 2,953 bytes at level L. A typical short URL like the default lands in version 2 or 3 at level M. Shorter content means a sparser, easier-to-scan code, so use a short link for long tracking URLs.
Error correction levels
The four levels trade capacity for damage tolerance: L recovers about 7% of damaged codewords, M 15%, Q 25% and H 30%. Higher levels add more correction codewords, which pushes the same content into a larger version. M is the right default for a URL on a screen or a flyer. Choose H if you plan to overlay a logo (keep it under about 20% of the area, centered) or print on packaging that will get scuffed. Pick L only for long text where you need the code to stay small.
Size, colors, Wi-Fi codes and printing
The image is drawn at an integer number of pixels per module so edges stay sharp, with the 4-module quiet zone the standard requires on every side; the exported PNG is therefore the largest exact multiple that fits inside the size you picked. For print, keep each module at least 0.5 mm - a code on a business card should be no smaller than 0.8 inch (2 cm). On screen, 150 px is the practical minimum. Dark foreground on a light background is essential; a reversed code (white on black) or a light pastel foreground will fail on many phones.
Wi-Fi mode builds the WIFI:T:WPA;S:name;P:password;; string that iOS and Android camera apps recognize, so guests can join your network by pointing their phone at a sticker. Special characters in the name or password are escaped automatically. The result is a static code: the content is baked into the pattern, it never expires, cannot be edited later, and nobody can count scans. For a URL, include the https:// prefix so the phone offers to open it directly.