QR (Quick Response) codes have become a dominant and trendy way of quickly sharing information.
QR codes are two-dimensional barcodes that can be read by scanners and smartphones. It can easily link physical information to digital information which is easily accessible via camera of smartphone or tablet.
And do you know anyone can generate QR codes and share their information in most interesting and fast way.
So, how can we generate QR codes? Excel, being a powerful spreadsheet program, allows you to generate QR codes within your worksheets.
Today, in this article, we will guide you through the process of creating QR codes in Excel with a in simple, fast and easy ways!
Method 1: Using Online QR Code Generators
One of the simplest ways to create a QR code in Excel is by using online QR code generators.
Let’s see how!
Step 1: Search your web browser for “online QR code generator.”
Step 2: Choose a reliable QR code generator website (e.g., QRCode Monkey, QRStuff, etc.).
Step 3: On the chosen website, select the data type you want to encode (e.g., URL, text, phone number, etc.).
Step 4: Enter the information in the provided field.
Step 5: Customize the QR code appearance if desired (colors, shapes, etc.).
Step 6: Generate the QR code and download it as an image file (e.g., PNG, JPEG).
Step 7: Open the Excel sheet where you want to add the QR code.
Step 8: Expand the cell’s dimensions where the downloaded QR image will be added. First, select the cell,
go to the ‘Format’ option within the cells section (as shown below)
Step 9: Select on ‘Row Height’ option. A new dialog box would open.
Step 10: Enter a suitable value for the row height after deleting the default number. Around 115 or greater would be ideal for QR image addition. Click on ‘Ok’.
Step 11: Go to ‘Format’ option again and select ‘Column Width’. Increase the value if needed and click on ‘Ok’.
Step 12: The cell size is now ready. Go to ‘Insert’ and click on ‘Illustrations’. Within ‘Illustration’, click ‘Pictures’ and then select ‘This device’.
Step 13: A new dialog box will appear to browse and select the downloaded QR code image. Double-click on the image file, and it will appear in your Excel sheet.
Step 14: Resize the image using the ‘dots’ to fit into the cell properly.
Note: If the you limited requirement to create QR codes is limited to few data set,- you can use this and/or the next option for generating QR code. However, in case you have large data set, then VBA is recommended.
Also read: How to Filter by Color in Excel?
Method 2: Using Excel Add-Ins
Here’s how to create QR codes using Excel add-ins:
Step 1: Navigate to the worksheet where you want to insert the QR code.
Step 2: Click on the “Insert” tab
Step 3: Look for “Get Add-ins” or “Office Add-ins” in the toolbar and click on it.
Step 4: Search for “QR code” or a specific QR code generator in the Add-Ins window.
Step 5: Install the desired QR code Add-In.
Step 6: Once installed, you will find a new option or button in the Excel ribbon for creating QR codes.
Sharing few examples here of creating QR codes.
- Example 1: Add a URL
- Add Customization (optional)- color, background, size change
- Click Insert
- Example 2: Add a text. From the drop-down option, select ‘Custom’ and add any text that would like to convert in QR code.
- Add Customization (optional)- colour, background, size change
- Click Insert
Note: If you want to create multiple QR codes, then this is a bit time consuming activity as you need to generate codes one-by-one.
Method 3: Using Macros or VBA Code
If you are comfortable with Macros or VBA (Visual Basic for Applications) coding, you can create QR codes programmatically within Excel with these steps:
Step 1: Open Excel and navigate to the worksheet where you want to insert the QR code.
Step 2: Press “Alt + F11” to open the Visual Basic for Applications (VBA) editor.
Step 3: Insert a new module by clicking “Insert” and selecting “Module.”
Step 4: Write or paste the QR code generation code in the VBA editor. Various libraries and code snippets are available online to help you accomplish this.
Step 5: Customize the code to specify the data to be encoded and any desired formatting options.
Note- Copy and Paste the code into the ‘Module’ section exactly as given below:
Function GenerateQR(qrcode_value As String)
Dim URL As String
Dim My_Cell As Range
Set My_Cell = Application.Caller
URL = "https://chart.googleapis.com/chart?chs=100x100&&cht=qr&chl=" & qrcode_value
On Error Resume Next
ActiveSheet.Pictures("My_QR_CODE_" & My_Cell.Address(False, False)).Delete
On Error GoTo 0
ActiveSheet.Pictures.Insert(URL).Select
With Selection.ShapeRange(1)
.Name = "My_QR_CODE_" & My_Cell.Address(False, False)
.Left = My_Cell.Left + 5
.Top = My_Cell.Top + 5
End With
GenerateQR = ""
End Function
Step 6: Press “F5” or use the “Run” option in the VBA editor to run the code.
Step 7: In a random cell, input a number that can be encoded into the QR code. This number would pop up if the QR is scanned.
Step 8: Input this code =GenerateQR(E3) into the cell where you want the QR Code to appear and press enter.
Note- Instead of ‘E3’, in the formula, you just need to add the cell name where you have just inputted the number in the previous step.
Method 4: Using QR Code Fonts
Step 1: Install the QR Code Font
First, install a special QR code font to generate QR codes in Excel.
Follow these steps to install the font:
- Search in your preferred web browser for “QR code font download.”
- Choose a reliable source like ‘Fonts4free.net’ or similar websites that provide a downloadable QR code font.
- Download the font file to your computer.
- Extract the font file (if necessary) and double-click on it.
- Click “Install” to install the font on your system.
Step 2: Prepare the Data
Before creating a QR code, ensure you have the data to be encoded ready in an Excel worksheet. It could be a website URL, contact details, or other text-based information. Input the data in any cell.
Step 3: Insert the QR Code
Follow these steps to insert a QR code into your Excel worksheet:
- Open Excel and navigate to the worksheet where you want to insert the QR code.
- Select the desired cell where the QR code should appear.
- Change the font of the selected cell to the QR code font you installed in Step 1.
Note– For reference, we will use the cell B3 containing the data in A3 for encoding.
- Select QR Font as the font to be applied in the cell. The cell will display a series of characters in the QR code font.
Step 4: Adjust the QR Code Size
Adjust the font size to increase or decrease the QR code’s size. You may need to experiment with different sizes to find the desired one. Click on the option highlighted in the image and select your desired QR code size.
Step 5: Customizing the QR Code (optional)
If you want to customize the appearance of the QR code, you can apply formatting options available in Excel.
Here are a few formatting suggestions:
- Change the cell background color to enhance visibility or match your design aesthetic.
- Adjust the font color to improve readability.
- Apply borders or cell styles to add visual appeal.
- Experiment with different font styles to find one that suits your needs.
Step 6: Test and Use the QR Code
Once you have created the QR code, testing it before sharing or using it is essential. Follow these steps to test the QR code:
- Scan the QR code using a scanning app on your smartphone or tablet.
- Verify that the scanned information matches the data you intended to encode.
- Make necessary adjustments if the QR code does not produce the desired result.
After testing, you can use the QR code by sharing the Excel file, printing it on physical materials, or exporting it as an image for online use.
Your text will now display as a series of QR codes!
Note: This will not convert entire text into a single QR code but each character of the text into a QR code!
Yes, we know- converting every character into a QR code is admittedly a futile task. Hence, we recommend you to use other mentioned methods.
Creating QR codes in Excel provides a convenient way to share information and engage users. Whether you prefer using online QR code generators, Excel Add-Ins, or leveraging Macros and VBA codes, Excel offers a range of options to suit your preferences and requirements.
Choose the method that seems the easiest to implement. You can easily find the most suitable process by trying the quick steps mentioned in the four methods above. If you want to explore more exciting hacks in MS Excel, visit TechGalaxy’s website now.
Other articles you may also like: