How to Put a QR Code in a Microsoft Word Document

by KoloQR TeamDesign

The Microsoft Word app icon beside a circular QR code with dot modules and round finder eyes, above a lime label reading "QR code in Word", on a dark grey background.

Word has no QR code button, but there are three reliable ways in. Paste a QR code image copied from a generator, which works in every version of Word. Insert an SVG file through Insert, then Pictures, which keeps the code sharp in Word 2019, 2021, 2024 and Microsoft 365. Or, on Windows only, type a DISPLAYBARCODE field such as { DISPLAYBARCODE "https://example.com" QR \q 3 } and let Word draw the code itself. The picture routes allow logos, shapes and colours; the field route keeps the link editable inside the document.

Key Points

  • Microsoft Word has no Insert > QR Code menu item. A QR code gets into a Word document as a pasted or inserted picture, or through the DISPLAYBARCODE field code.
  • A QR code pasted or inserted as a PNG picture works in every version of Word on Windows, Mac, the web and mobile.
  • Word inserts SVG files in Word 2019 and later and in Microsoft 365 on Windows, Mac and Android. Microsoft states that SVG images cannot be inserted on iOS.
  • The DISPLAYBARCODE and MERGEBARCODE fields are documented by Microsoft for Word for Windows desktop only. On Word for Mac the same field is reported to display Error!.
  • Word compresses pictures to 220 ppi by default in Microsoft 365. For a printed QR code, use SVG or turn on "Do not compress images in file" before saving.

Three Ways to Put a QR Code in Word, Compared

Choose the route by what the QR code has to do. Use a pasted or inserted PNG when the document must open everywhere. Use an SVG when the Word document will be printed and everyone runs Word 2019 or later. Use the DISPLAYBARCODE field when the link must stay editable inside the document, or when one document needs many codes from a list.

RouteWorks inDesign controlLink editable laterBest for
PNG picture (pasted or inserted)Every Word version, Windows, Mac, web, mobileFull: shapes, colours, frame, logoNo - replace the pictureDocuments shared with unknown recipients
SVG picture (inserted)Word 2019 and later, Microsoft 365 on Windows, Mac and Android; not iOSFull: shapes, colours, frame, logoNo - replace the pictureFlyers, posters and other printed Word documents
DISPLAYBARCODE fieldWord 2013 and later for Windows desktopSquare modules, foreground and background colour onlyYes - edit the field code and press F9Templates, forms and documents whose link changes
MERGEBARCODE field (mail merge)Word for Windows desktopSquare modules, colour onlyYes - edit the data source and merge againLabel sheets, badges and certificates with a different code each

Two rules settle most cases. If anyone will open the Word document on a Mac, an iPad or in a browser, avoid the field and use a picture. If the QR code needs a logo, rounded modules, a circular shape or a frame, use a picture from a generator, because the DISPLAYBARCODE field draws only plain square modules.

How to Insert a QR Code Image in Word

Inserting a QR code image into Word takes under a minute: generate the code in a browser, copy it as an image, click where it belongs in the document, and paste. Downloading the file and choosing Insert, then Pictures, gives the same result and is the route to use for SVG.

  1. Generate the code. Open the generator, enter the URL or other content, and set the shape, colours, frame and logo. Style the code before it reaches Word, because Word can resize a picture but cannot redraw it.
  2. Copy it or download it. Open the Free Download panel and choose Copy image, which puts a PNG on the clipboard. For print, choose SVG instead, which downloads a vector file. If the browser blocks the clipboard, Copy image downloads the PNG file.
  3. Place the cursor in Word. Click the spot in the document where the QR code should sit. A code pasted into a table cell takes the cell's width as its limit, which is a convenient way to fix its size on a form.
  4. Paste or insert. Press Ctrl+V on Windows or Cmd+V on a Mac to paste a copied image. For a file, choose Insert, then Pictures, then This Device on Windows, or Insert, then Pictures, then Picture from File on a Mac.
  5. Set the size with the aspect ratio locked. Right-click the picture, open Size and Position, confirm Lock aspect ratio is ticked, and type the width. Width and height must stay equal.
  6. Scan it on screen. Zoom to 100% and scan the code from the monitor with a phone. Confirm that the address that opens is the one you intended before sending or printing the document.

Word places a new picture "In Line with Text" by default, which means the QR code moves with the paragraph like a large character. Inline placement is the safest choice for a QR code, because text cannot flow into the margin around it. Square wrapping also works if the distance from text is set to a few millimetres; Tight and Through wrapping let text run close to the symbol and eat into its quiet zone.

Insert the file rather than paste it when transparency matters. A clipboard image can lose its transparent background on the way into Word, while an inserted PNG file keeps it. For most documents this does not matter, because a QR code should sit on a solid white or light background anyway.

PNG or SVG: Which QR Code Format to Use in Word

Use SVG for a Word document that will be printed, and PNG for a document that will be emailed to people whose Word version you do not know. SVG stays sharp at any size and is not touched by Word's picture compression; PNG opens in every version of Word, including versions too old to display SVG.

QuestionPNGSVG
Opens in Word 2016 and earlierYesNo - older versions show a blank box or refuse the file
Opens in Word 2019, 2021, 2024, Microsoft 365YesYes, on Windows, Mac and Android
Opens in Word on iPhone and iPadYesCannot be inserted on iOS, per Microsoft
Affected by Word's picture compressionYes, unless compression is turned offNo - vector shapes have no pixels to resample
Sharp when enlarged in the documentUp to its pixel sizeAt any size
Can be pasted from the clipboardYesNo - insert the file
KoloQR exports both. The PNG is rendered at 40 pixels per module, about 1,640 pixels for a typical short URL.

A PNG from KoloQR at 40 pixels per module prints cleanly up to roughly its pixel width divided by 300, times 2.54 centimetres. For a typical 1,640-pixel code that is about 14 cm, which covers any QR code on an A4 or Letter page. The limit only matters when Word's own compression lowers the pixel count first, which the section on blurry codes covers.

Do not use Convert to Shape on an inserted SVG QR code. Word's Convert to Shape option breaks the SVG into separate shapes so they can be edited, which serves illustrations but not QR codes: the code needs to be placed and sized, never redrawn. For more on the two formats, see SVG vs PNG.

How to Make a QR Code in Word With the DISPLAYBARCODE Field

Word for Windows can draw a QR code itself with a field code. Press Ctrl+F9 to insert field braces, type DISPLAYBARCODE "https://example.com" QR \q 3 between them, then press Shift+F9 to show the result. No add-in is needed. The field works in Word 2013 and later on Windows desktop, not on Mac, the web or mobile.

  1. Insert empty field braces. Click where the QR code should go and press Ctrl+F9. Word inserts a pair of grey field braces. Typing the { and } characters on the keyboard does not work; Word only treats braces inserted this way as a field.
  2. Type the field code. Between the braces, type DISPLAYBARCODE "https://example.com" QR \q 3, replacing the address with your own. Keep the content in straight double quotes.
  3. Show the QR code. With the cursor inside the field, press Shift+F9 to switch from the code to its result. Alt+F9 switches every field in the document at once.
  4. Update after an edit. To change the link, press Shift+F9 again to show the code, edit the address, then press F9 to update the field. On laptops where the function keys control volume or brightness, hold Fn as well.
  5. Scan the result. Scan the QR code from the screen with a phone and confirm the address. If Word shows Error! instead of a code, the troubleshooting section below lists the causes.

The field's switches control error correction, size, colour and rotation. Microsoft's support page and its file-format specification describe the error correction switch differently, so the table gives both forms.

SwitchWhat it setsAccepted values
\qError correction level0 to 3 on Microsoft's support page; L, M, Q or H in its file-format specification. Both documents use the highest value, 3 or h, in their examples
\sScale of the symbolWhole percentages from 10 to 1000
\hHeight of the symbolTwips: 1440 per inch, about 567 per centimetre
\fForeground (module) colourA hexadecimal value from 0x000000 to 0xFFFFFF
\bBackground colourA hexadecimal value from 0x000000 to 0xFFFFFF
\rRotation0 to 3
\tShows the encoded text under the symbolNo value
Source: Microsoft Support, "Field codes: DisplayBarcode field", and the [MS-OI29500] specification, both read 25 October 2026.

A complete field for a 3 cm QR code with the highest error correction looks like this: { DISPLAYBARCODE "https://example.com/menu" QR \q 3 \h 1701 }. The 1701 comes from 3 × 567 twips. Measure the printed result with a ruler the first time, and adjust \h or \s if your version of Word draws the code at a different size.

Set the size inside the field code rather than by dragging the result. The DISPLAYBARCODE field is redrawn every time it updates, so a size that only exists as a manual resize can be lost the next time someone presses F9 or prints the document.

Keep colour switches conservative. Microsoft documents the range of \f and \b but not their byte order, so a value that looks like dark red may come out as another colour. Dark modules on a white background - the default when both switches are left out - is the combination every scanner reads. Check any custom pair with the contrast checker before printing.

How to Make QR Code Labels in Word With Mail Merge

Word for Windows can print a different QR code on every label, badge or certificate with the MERGEBARCODE field. Put the links in an Excel column, start a Labels mail merge, insert a field such as { MERGEBARCODE URL QR \q 3 } where URL is the column name, then update the labels and finish the merge.

  1. Prepare the list. In Excel, put one link per row in a column with a one-word header such as URL. Add columns for any text that should print beside the code, such as a name.
  2. Start a labels merge. In Word, choose Mailings, then Start Mail Merge, then Labels, and pick the label product and number that match your sheet.
  3. Connect the list. Choose Select Recipients, then Use an Existing List, and open the Excel file and sheet.
  4. Insert the barcode field. Click in the first label, press Ctrl+F9, and type MERGEBARCODE URL QR \q 3 between the braces, using your own column header in place of URL. Add any Insert Merge Field entries for the text.
  5. Copy the layout to every label. Choose Update Labels so the first label's layout repeats across the sheet, then choose Preview Results to see real codes.
  6. Finish and test. Choose Finish & Merge, then Edit Individual Documents. Scan the first and last code in the merged document before printing the whole run.

Size the code to the label, not the other way round. A standard address label is about 2.5 cm tall, which leaves room for a QR code of roughly 2 cm with its quiet zone - the practical minimum for close scanning. Labels smaller than that suit short links only, because a longer link adds modules and shrinks each one.

Mail merge is the one job where the field route clearly beats a generator. Making forty different codes by hand in a browser is slow and error-prone; MERGEBARCODE turns the same forty rows into forty codes in one merge. The trade-off is design: every merged code has plain square modules and no logo.

What Size Should a QR Code Be in a Word Document?

A QR code in a printed Word document should be at least 2 × 2 cm, including its quiet zone, for scanning from close up. As a rule of thumb, allow about 1 cm of width for every 10 cm of scanning distance: 2.5–3 cm on a handout read at arm's length, about 20 cm on a poster read from 2 metres.

Word documentTypical scanning distanceQR code width
Business card or label15–20 cm2–2.5 cm
Letter, invoice or handout25–30 cm2.5–3 cm
A5 flyer or table card30–50 cm3–5 cm
A4 or Letter notice on a wall1 mAbout 10 cm
A3 poster2 mAbout 20 cm
Rule of thumb: 1 cm of code for every 10 cm of distance, with 2 cm as the floor. Longer links need the larger end of each range.

Word's Size box measures in centimetres or inches depending on the system settings, so type the width directly rather than dragging. If a dragged corner is unavoidable, hold Shift while dragging to keep the proportions. A QR code stretched by even a few percent on one axis can stop scanning while still looking square on screen.

The size includes the quiet zone, the white margin of four modules around the symbol. Never crop that margin with Word's Crop tool to make the code fit a layout, and never let a coloured table cell, shape or page background run into it. For the full arithmetic, see QR code minimum size for print or enter your distance in the print size calculator.

Why a QR Code Looks Blurry in Word, and How to Stop It

Word compresses pictures when a document is saved. In Microsoft 365 the default target is 220 ppi, so a sharp QR code PNG can be resampled and its module edges softened. Use an SVG instead, or turn compression off in File, then Options, then Advanced, under Image Size and Quality, by ticking "Do not compress images in file".

Compression usually does not stop a QR code from scanning, but it costs margin. A 3 cm QR code with 41 modules, downsampled to 220 ppi, keeps about 6 pixels per module. That is enough for most phone cameras on screen; on paper, soft edges and printer ink spread combine, and a code that was marginal on contrast or size becomes the one that fails.

The "Do not compress images in file" setting applies to the current document and can make the file larger. The High fidelity option in the same section has a similar effect. Microsoft notes that these settings exist in the desktop apps only, not in Word for the web.

When saving a Word document as PDF on Windows, choose the standard option for publishing online and printing rather than minimum size. Microsoft describes the minimum-size option as lower quality, and a print shop working from a PDF will print whatever pixels the PDF contains. Check the exported PDF by zooming to 400% on the QR code: module edges should be crisp, not grey and stepped.

Why a QR Code in Word Is Not Scanning or Shows Error!

Most QR code problems in Word come from the document, not the code: a field Word cannot evaluate, a picture stretched on one axis, a quiet zone cropped or covered, compression, or low contrast. Each has a specific check, listed below.

  • The field shows Error!. The document is open in Word for Mac, the web or mobile, which do not support the field; the braces were typed instead of inserted with Ctrl+F9; or the content does not meet the barcode's requirements. Open the document in Word for Windows, re-insert the braces, and check the quotes around the content.
  • The field shows its code instead of a QR code. Field codes are switched on. Press Alt+F9 to switch every field back to its result, or Shift+F9 inside one field.
  • The field does not change after editing the link. Fields do not update on their own. Click inside the field and press F9, or select the whole document with Ctrl+A and press F9.
  • A link with spaces fails. Spaces and some special characters in a URL can stop the field from rendering. Encode spaces as %20, or shorten the link before putting it in the field.
  • The picture scans on screen but not on paper. The code is too small for the distance, compressed, or printed on a coloured or glossy background. Check the size table above and turn off compression.
  • The code is slightly rectangular. Lock aspect ratio was off when the picture was resized. Reset the picture with Picture Format, then Reset Picture and Size, and set the width again.
  • Text sits right against the code. Tight or Through wrapping lets text into the quiet zone. Switch the picture to In Line with Text or Square wrapping.

If the code still fails, the problem is usually in the symbol rather than the document. Work through why a QR code is not scanning, which covers contrast, damage and phone camera behaviour in more depth.

A QR code inserted into Word as a picture cannot be edited; changing the link means generating a new code and replacing the picture. A DISPLAYBARCODE field can be edited: show the field code with Shift+F9, change the address, and press F9. Either way, a code that has already been printed keeps its old link.

Both kinds are static QR codes. A static QR code stores its destination in the pattern itself, so the code works without any service in between and never expires, but the pattern has to change when the destination changes. The field route makes that change cheap inside the document; it does nothing for paper already in circulation.

If a printed document needs a link that can change later, or scan counts, a dynamic QR code from a hosted platform is the right tool. It points to a short redirect address that the platform can repoint. The trade-off is a dependency: the code stops working if the subscription or the service ends. See static vs dynamic QR codes for the full comparison.

A practical alternative for Word templates is to point the code at a page you control, such as your own website's /menu or /contact address. The QR code in the template never changes, and the page behind it can be updated as often as needed.

QR Codes in PowerPoint, Outlook and Other Office Tools

The picture routes work across Microsoft 365: PowerPoint, Outlook and Excel insert SVG and PNG QR codes through Insert, then Pictures, the same way Word does. The DISPLAYBARCODE and MERGEBARCODE fields are Word features; PowerPoint and Excel have no equivalent field.

  • Microsoft 365 Copilot Chat. Microsoft documents a Copilot Chat feature that generates a QR code for a URL, which can then be copied or downloaded and pasted into Word.
  • QR4Office. A free add-in on Microsoft AppSource for Word, Excel and PowerPoint. It is published by an independent developer, not by Microsoft, so check its current status and permissions before installing it in a work account.
  • Google Docs. Google Docs has no barcode field. Insert a QR code there as a PNG image through Insert, then Image.

KoloQR, a free QR code generator with circular and custom-shaped QR codes, exports PNG, SVG, PDF and EPS, and copies a PNG straight to the clipboard for pasting into Word. The same file works in every Office app, so one code can go into a Word letter, a PowerPoint slide and an Outlook signature without being made three times. For the design options, see round QR codes and branded QR codes.

Checklist Before You Print or Send the Word Document

  • The QR code opens the intended address, checked character by character, including https and any tracking parameters.
  • The code is at least 2 × 2 cm, and larger for anything read from more than about 20 cm away.
  • Width and height are equal, set numerically with Lock aspect ratio ticked.
  • A white margin of four modules surrounds the code, with no text, shape or background colour inside it.
  • The document uses SVG, or picture compression is switched off, if it will be printed.
  • Any DISPLAYBARCODE fields show their result, not their code, and have been updated with F9.
  • The exported PDF, not the Word file, has been scanned, if the printer works from PDF.
  • One copy has been printed at final size on the real paper and scanned with both an iPhone and an Android phone.

The last item catches what a screen cannot show. Paper, ink and room lighting change how a QR code reads, and a single test print costs less than reprinting a run. The print checklist covers the same checks for any printed QR code, not only Word documents.

Make Your QR Code

Free, with no account and no watermark. Choose a shape, add a logo, check the contrast, and export SVG, PDF, EPS or PNG - a static code with no subscription behind it.

Generate QR Code

Questions? Answered

Not as a menu button. Word for Windows can draw a QR code through the DISPLAYBARCODE field code, which is inserted with Ctrl+F9 and typed by hand. On Mac, the web and mobile there is no built-in way, so a QR code has to come in as a picture from a generator.

Yes, as a picture. Copy the QR code image from a generator and press Cmd+V, or choose Insert, then Pictures, then Picture from File; Word for Mac in Microsoft 365 and Word 2019 or later accepts SVG as well as PNG. The DISPLAYBARCODE field is documented for Windows only and is reported to show Error! on a Mac.

Yes, as a PNG. Save or copy the QR code image on the device, then insert or paste it into the document. Microsoft states that SVG images cannot be inserted in Word on iOS, and the barcode fields are a Windows desktop feature, so PNG is the only route that works on an iPhone or iPad.

Only for people opening it in Word for Windows. On a Mac, in a browser or on a phone the field may show Error! instead of the code. Before sending, either save the document as PDF, which fixes the drawn code in place, or replace the field with a picture of the QR code.

Not with the DISPLAYBARCODE field, which draws plain square modules and offers only colour switches. Pasting a logo on top of a field code risks covering too many modules. Make the code with the logo in a generator instead, at a high error correction level, and insert it as a picture.

Word compressed the picture when the document was saved, or the PNG was too small for its printed size. Insert the code as SVG, or tick "Do not compress images in file" in File, then Options, then Advanced, then insert the picture again, since already-compressed pixels cannot be recovered.

Yes. A picture from a generator can use any colours, and the DISPLAYBARCODE field takes \f for the module colour and \b for the background. Keep the modules much darker than the background: scanners reduce the image to black and white, so a mid-tone code on a mid-tone background fails even when it looks clear on screen.

Yes, if the PDF is saved for printing rather than for minimum size. A PNG keeps only the pixels Word left after compression, so check the result rather than assume it. Open the PDF, zoom in on the code to check the edges are crisp, and scan it once from the PDF itself.

Click inside the table cell, paste or insert the QR code picture, and set its width in the Size box so it fits inside the cell. Set the cell's padding so a white margin stays around the code, and avoid shading the cell, because a coloured cell background becomes the code's quiet zone.

No. Both the DISPLAYBARCODE field and a pasted picture from a static generator produce static QR codes, which store the link in the pattern and work for as long as the link itself works. Only dynamic codes from subscription services can stop working, when the service redirecting them ends.

Why KoloQR?

  • Create QR codes for websites, menus, Wi-Fi, PDFs, and business cards
  • Customize colors, logos, and unique shapes
  • Download high-quality PNG and SVG files
  • Built for both print and digital
Generate QR Code
A plain black QR code beside the same code restyled as a circle with brand colors