A laptop shows a Word document with a QR code, beside a printed copy of the same page

To put a QR code in a Word document, an Excel sheet or a PowerPoint slide, make the code in the maker, download it as an SVG (or a PNG of 1024 px or more), then use Insert, Pictures in the Office app. Resize it from a corner so it stays square, and scan it on screen before you share or print the file.

Word has two extra tools: a DISPLAYBARCODE field that draws a code from text you type, and a MERGEBARCODE field that makes one code per row of a list during a mail merge. Excel has no QR function, and PowerPoint needs a bigger code than you think, because people scan from their seats.

Insert a QR code image in any Office file

This route works the same in Word, Excel, PowerPoint and Outlook, and it covers every type of code: links, Wi-Fi, contact cards or plain text.

  • Make the code in the maker and download the SVG file.
  • In the Office app, choose Insert, Pictures, This Device, and pick the file.
  • Drag a corner handle to resize it. A corner keeps the shape square; a side handle stretches it and can stop phones from reading it.
  • Leave the white margin around the code, and do not set the picture behind text or on a coloured shape.

Pick SVG when the file can take it. By default, Office compresses pictures in a document to save space, and a small PNG enlarged for print can turn soft at the edges. An SVG is drawn from shapes, so it stays sharp at any size.

Make a QR code with Word's DISPLAYBARCODE field

Desktop Word for Windows can draw a QR code without any add-in. The code lives in the document as a field, so you can edit its text later.

  • Place the cursor where the code should go and press Ctrl+F9. Word inserts a pair of field braces.
  • Between the braces, type: DISPLAYBARCODE "https://example.com" QR \q 3
  • Press F9 to update the field. The code appears.
  • Press Alt+F9 to switch between the code and the field text when you need to change the link.

The \q switch sets the error correction level, from 0 (lowest) to 3 (highest), and \s scales the code. Type the braces with Ctrl+F9: braces typed from the keyboard are plain text and draw nothing.

A field code makes link and text codes well. For Wi-Fi or a contact card, the text format is long and easy to get wrong, so make the code in the maker and insert the image instead.

Make a batch of QR codes from an Excel list

Word's mail merge reads a list and repeats a layout for each row. With a MERGEBARCODE field in the layout, every label gets its own code. This is the free way to print codes for a product range, a room list or a set of event badges.

  1. Build the list in Excel

    Put a header in the first row, such as Name and Link, and one item per row below it. Save the workbook and close it.

  2. Start a label merge in Word

    In a new Word document, open Mailings, Start Mail Merge, Labels, and pick your label sheet brand and size.

  3. Connect the list

    Choose Select Recipients, Use an Existing List, and open the workbook and the sheet that holds your rows.

  4. Add the barcode field

    In the first label, press Ctrl+F9 and type MERGEBARCODE Link QR between the braces, using the name of your link column. Add Insert Merge Field for the name if you want text beside the code.

  5. Fill every label

    Click Update Labels so the layout repeats, then Finish and Merge, Edit Individual Documents. If the codes show as field text, select all and press F9.

  6. Test before the full print

    Print one sheet on plain paper and scan several codes, including the first and the last, before you load the label stock.

A sheet of printed QR code labels coming out of an office printer

QR codes in Excel: what works and what to avoid

Excel has no built-in function that draws a QR code. For a few codes, make each one in the maker and insert it as a picture in its cell. For a long list, the Word mail merge above is the cleaner route.

  • Some guides use the IMAGE function with an online QR service in the address. It works, but every link in your sheet is sent to that service, and the codes vanish if it goes offline or changes its address format.
  • Add-ins from the Office store can generate codes in cells. Check who publishes the add-in and what data it reads before you install it, above all on a work account.
  • A picture inserted in a cell does not update when the cell text changes. Remake the code when the link changes.

Microsoft Forms and Edge already make QR codes

Two Microsoft tools make a code for you, with no file to manage:

  • Microsoft Forms: open your form, choose Collect responses, then the QR code option, and download the image to share the form on paper or a slide.
  • Microsoft Edge: open the page you want to share, open the share menu, and pick the QR code option. Edge shows a code for the page address that you can download.

Both make link codes only. For anything else, use the maker and insert the file.

QR codes on PowerPoint slides people scan from their seats

Insert the code with Insert, Pictures, as an SVG. On a slide, the size that counts is the size on the screen, not on your laptop. The rule of thumb from the size guide still applies: the code should be about one tenth of the scanning distance.

  • For a back row 6 metres from the screen, the code needs to show about 60 cm wide on the projected image.
  • Give the code its own clear space on the slide, with no animation and no photo behind it.
  • Leave the slide up long enough to scan: people need time to open their camera, and the back rows scan last.
  • Write what the code opens on the slide, such as Scan for the slides or Scan to give feedback.
A meeting room screen shows a slide with a large QR code, seen from the back row

Questions about QR codes in Office files

A code that will not scan or a type you are missing? We answer every message.

Ask a question
A laptop on a desk with a Word document open, showing a QR code at the top of the page

Does Word have a built-in QR code generator?

Yes, desktop Word for Windows has the DISPLAYBARCODE field. Press Ctrl+F9, type DISPLAYBARCODE, your link in quotes and QR, then press F9 to draw the code. For several codes from a list, use MERGEBARCODE in a mail merge. If you prefer no fields, make the code in a generator and insert the image.

How do I make many QR codes at once from Excel?

Keep the list in Excel with one link per row and a header row, then run a label mail merge in Word. Connect the workbook, put a MERGEBARCODE field with your link column name and QR in the first label, update the labels and merge. Word then gives you one code per row, ready to print.

Why is my QR code blurry when I print the document?

Office compresses pictures by default, and a small PNG stretched to a larger size loses its sharp edges. Insert the code as an SVG, which stays crisp, or use a PNG of 1024 pixels or more. When you save a PDF for print, choose the standard option, not the minimum size one.

How big should a QR code be on a PowerPoint slide?

Size it for the farthest seat. A code roughly one tenth of the scanning distance works well, so a back row 6 metres away needs about 60 centimetres on the projected image. Keep it on a plain light area of the slide and leave the slide up long enough for the room to scan it.