QR Code and 2D Code Generator

This page is an online two dimensional code generator which is written in PHP. It can generate QR Code, Data Matrix, Aztec Code and Micro QR Code.

Using the form on this page, you can create two dimensional code images that trigger various actions on the scanner device. Don’t forget to install Qrafter or Qrafter Pro (why two versions?) to scan and generate QR Codes if you have an iPhone or iPad. So far, this page created 4,893,830 codes since I started counting in January, 2010.

Please be sure to read the Notes and FAQ sections below before requesting help in the comments if you encounter any problems with code generation (Especially for Micro QR Codes or backslash characters you may encounter on some codes!).

This page is very popular and because of that, it gets an incredible amount of comment spam. Sometimes legitimate comments can get caught as spam and I can miss them, so if your comment does not appear after some time, you can contact me from the email address on my contact page.

READ THIS FIRST:

I am getting many questions about scanning the codes created on this generator. Most of them are about some problem with the scanner not detecting the content of the code properly. This generator follows established standards strictly and most scanner apps except Qrafter and Qrafter Pro for iOS don’t follow those standards completely. So, if you somehow end up with an unexpected result after scanning a code, it is because that your scanner was developed lousily. If you are on iOS, use Qrafter or Qrafter Pro for guaranteed standards compatibility. For other platforms, please contact the developers of your scanner app to tell them to start following the standards that were established for a reason.

Select a Code Action:
Code Type: QR Code (recommended)
Data Matrix (only ASCII chars)
Aztec Code (only ASCII chars)
Micro QR Code (only ASCII chars)
Bookmark Title: *
Web Site URL: *
Phone Number: *
SMS Message:
Mail Recipient: *
Subject:
Body:
Escape Special Characters (like colon, semicolon or comma): Yes
No
IMPORTANT: Please check notes on escaping in Notes section.
Version: 2.1
3.0
vCard Type: Real Person
Company
First Name:
Middle Name:
Last Name:
Organization:
Title:
E-Mail Address:
Mobile Phone:
Video Call Phone:
Work Phone:
Work Fax:
Home Phone:
Work Address: Street:
City:
State:
ZIP Code:
Country:
Home Address: Street:
City:
State:
ZIP Code:
Country:
Address: Street:
City:
State:
ZIP Code:
Country:
Work Web Address:
Home Web Address:
Web Address:
Birthday:
Event Format: Fully Compliant to iCalendar Standard Compliant to ZXing Proposal
Event Summary: *
Event Description:
Full Day Event: Yes (Only uses start date and end date) No (Also uses start time and end time)
Start Date:
Start Time:
End Date:
End Time:
Text: *
NOTE: Google Maps will be used to select the coordinates, but the resulting url will be a Bing Maps URL.
Location Name:
 
Twitter User: *  
Prepend username before tweet
Twitter User: *
Text to Tweet: *
Search Type: Publisher Search Exact Package Name
Market Search: *
Package Name: *
Youtube Video ID: *  
Enter either only the YouTube video ID or full URL for the video.
iTunes App ID: *  
Enter either only the App ID or full URL for the app on iTunes.
Venue ID: *  
Enter either only the venue ID or full URL for the venue.
Facebook Status: *
BBM Pin: *
SSID: *
Password:
Network Type:
URL Shortening:
(will use full url in case of error)
Error Correction Level:
(only for QR Code)
Block Size in Pixels:
Margin Size in Blocks:
Output Type:
Foreground Color:     Transparent
Background Color:     Transparent
Qrafter Banner

Notes:

You can follow me or Qrafter on Twitter.

QR Code is far more widespread than Data Matrix, Aztec Code or Micro QR Code. Actually Micro QR Code is rarely used and is only given here as a technology preview. If you want to create a campaign for your products using a 2D Code, make sure that you are using QR Codes, not the other types.

Data Matrix and Aztec Code have significantly lower capacity (4096 alphanumeric characters for QR Code, 3067 for Aztec Code and 2335 for Data Matrix), so if you would like to encode a lot of text, select QR Code.

To create the best readable code for long URLs, use one of the URL shortening services so that the resulting code is as small as possible. I personally prefer bit.ly over the others.

Micro QR Code cannot hold more than 35 numeric and 21 uppercase alphanumeric characters, and it can hold even less characters when you use lowercase characters. When encoding a URL into a Micro QR Code, try using all uppercase characters for longer URLs. I don’t know of a scanner that supports Micro QR Code though.

If your input cannot be encoded, the generator will give a warning. In that case, lower the character count in your input and try again.

If your device cannot interpret the encoded 2D Code properly, it probably means your scanner program is written poorly or does not have the capability of decoding that particular code format; or your device does not accept that action, because all codes created by this script and the content within them are compliant to all necessary published standards (vCard standards, URL encoding schemes, NTT DoCoMo standards, etc.).

While we are talking on standards, let me open the topic up a little bit more. Sadly most scanners out there do not follow special character escaping standards. Characters like “:” or “;” are special characters in vCard, meCard or vEvent specifications, and they should be properly escaped for the input to be interpreted correctly. This generator follows these standards correctly, and so a URL field like “http://example.com” becomes “http\://example.com” after escaping. The problem is, some scanners do not know how to handle this escaped character and break altogether. If you encounter such problem, select No for Escape Special Characters in vCard, meCard or vEvent creation. But while you will be able to read those QR Codes in broken scanners, be aware that, your 2D Code will not be standards compliant and you may not be able to add a URL that includes a second colon (for example as a port number separator) or semicolon when you do that. If you are on iPhone or iPad, I strongly suggest that you ditch your broken scanner and download Qrafter or Qrafter Pro. They are fully compliant to said standards. This way, I hope that developers will be forced to create scanners that obey standards that were established for a reason.

Data Matrix, Aztec Code and Micro QR Code do not support characters other than ASCII because of their spec, so if your input has international characters, always use QR Code. Another caveat of Micro QR Code is that, it is not supported by most of the scanner programs out there. As for Kanji and Cyrillic characters, again, only QR Code should support them.

Always use dark colors for foreground color and light colors for background color. If there is not enough contrast between foreground and background colors, your device will most probably fail to decode the code. Another warning: The EPS version I had to use does not support transparency, so you should use another format if you are going to have transparent foreground or background in your codes.

Twitter Profile Image Overlay option overlays your Twitter profile image onto a code that includes your Twitter profile URL. Images created with this option will behave very oddly with vector image formats. You have been warned! 🙂

Currently you can do the following actions with 2D codes generated with this form:

  • You can browse to a website.
  • You can bookmark a website.
  • You can make a phone call.
  • You can send a short message.
  • You can send an e-mail.
  • You can create a vCard (v2.1 or v3.0) with coordinates to add a contact to your device.
  • You can create a meCard to add a contact to your device.
  • You can create a vCalendar event to add to your calendar.
  • You can create iTunes app and review URLs for iOS devices.
  • You can create market:// URLs for searching for publishers or packages on Market app for Android.
  • You can create Foursquare venue URLs.
  • You can create special youtube:// URLs for YouTube app on iOS.
  • You can fetch and encode the latest tweet of a Twitter user.
  • You can overlay a Twitter profile image over the code.
  • You can create a mobile URL to tweet on Twitter.
  • You can connect to a WIFI network on Android devices.
  • You can read plain or free formatted text on your device.

You can change the block size of the generated image to make it bigger or smaller. Also, you can change the margin size of the image to add more quiet zone if your decoder cannot decode it (Especially Data Matrix seems to need bigger margin sizes). Error correction level for QR Code (ignored for other code types) can be set to 4 different values and higher values may cause the image to be decoded slightly slower. The 4 values can be explained like this:

  • Low (L): Up to 7% of errors can be corrected.
  • Medium-Low (M): Up to 15% of errors can be corrected.
  • Medium-High (Q): Up to 25% of errors can be corrected.
  • High (H): Up to 30% of errors can be corrected.

You can choose PNG, PDF, SVG or EPS outputs. SVG will output a vector image XML file, and you can edit it in applications like Adobe Illustrator or Inkscape.

Please be aware that while I make checks for illegal characters to protect my server, I do not check your input for a meaningful value.

The image generation is done using third party encoders. I have only written a handy PHP front end that formats your input and passes it to these encoders.

A note about printing from Roy, a fellow user of this generator: When codes are generated, they are created in RGB (my note: yes even if they are black and white, they are in RGB colorspace) and if they are used in printing, they should be converted to grayscale or CMYK so that, when printed, only the black plate is used. This ensures the highest edge resolution, particularly in smaller sizes.

QR Code Scanners:

The best scanner apps for iPhone and iPad are Qrafter and Qrafter Pro. They are available on the App Store. They are designed for both iPhone and iPad and Qrafter is free with advertisements, while Qrafter Pro is paid with no advertisements. They are able to understand all actions on this generator (and more) and are the most advanced scanners for QR Codes on iPhone and iPad.

For Android, the best option seems to be the Barcode Scanner app from ZXing.

For Nokia Maemo/Meego, you can use Mbarcode according to Ryks, another commenter.

For other devices, you may find one, suitable for your device from Kaywa or QuickMark.

QR Code is a registered trademark of DENSO WAVE INCORPORATED in the United States and other countries.

Qrafter is a registered trademark of Kerem Erkan in the United States, European Union and other countries.

FAQ:

Here is an updating list of frequently asked questions.

Q: Can I change the content of a code I created if I find a mistake?
A: The codes generated on this generator are standalone, which means they have no connection to this generator after being generated. This also means they include the content directly inside them, and if the content needs to change, the generated code image will change. Please test your code images with as many devices and scanner apps as possible to avoid any problems after printing the codes.

Q: Why do I get unwanted characters like a backslash (\) or semicolon (;) in the result when I scan a QR Code?
A: You are using a QR Code reader that cannot parse the contents of QR Codes correctly. Many readers are especially weak at parsing vCards. Use a proper app from the QR Code Scanners list on this page.

Q: Do you harvest the information I enter into this form?
A: No, I don’t use the information you enter to this form in any means. After you create your 2D Code, the information is removed from my server.

Q: Can I track the scan information for the 2D Codes I create on this generator?
A: You can’t track the 2D Codes you create on this generator unless you create your own trackable URL (for example a bit.ly URL) and then enter that URL to generate a QR Code for it on this page.

Q: Do the 2D codes that were created on this generator have an expiration date?
A: No, all codes generated on this generator can be used as long as you want.

Q: Can I use the codes I create on this generator commercially? Do I need to pay any fees?
A: You can use the codes created on this generator both commercially and personally. There are no fees to pay. The only favor I ask back is the promotion of Qrafter or Qrafter Pro on your site as your recommended reader app for iOS devices. But it is only a request, you are not obliged to do that. 🙂

Q: What is the minimum size for a QR Code so that it can be scanned with all devices?
A: The answer to this question cannot be given with exact proportions. New devices with autofocus cameras can scan very small QR Codes, but old devices that don’t have autofocus cameras will have problems with scanning codes smaller than one or two inches. Also it depends on the size of the information that you put into the QR Code. You need to test your QR Code with many devices, old and new to find the best compromise.

Q: Can I overlay an image on top of the QR Code like the one in “Twitter Profile Image Overlay” action of this generator?
A: Yes you can. Create a QR Code with highest error correction and select a vector output. This way, using your preferred image editor, you can overlay an image that’s up to 30% of the QR Code. Be careful not to overlay the image on top of the 3 alignment squares though.

1,119 thoughts on “QR Code and 2D Code Generator”

    1. Are you using an iPhone? You just need to open some text editor (like Notes or Mail) and tap and hold. You can paste it that way.

  1. Hi,

    Love your site.

    I am trying to embed a URL in Free Text. This works great with Droid but does not work with Blackberry or Iphone.

    Any suggestions?

    Thanks

        1. I understand. Qrafter does not support that currently, but I’ll add support for this to a later release. I don’t know what can you do on Blackberry though.

  2. Great work Kerem. Your blog is very useful. I just have a quick question about the QR codes generated via this page. Do these QR codes have a fixed life span? I mean for how long would the QR code images be active for?

    Cheers
    GV

    1. Hi,

      Thanks! The QR Codes don’t have any life span. They are standalone and can be used as long as you want. They also don’t have any connection to my site.

  3. Hello again Kerem. I figured out what I did wrong with the donation. I just made a successful donation. Thanks again and if you have ideas for the question I posted, I would love to hear them.

    1. Hi Kelly,

      You can create a simple mobile web page for that, which asks for the student name and enters that information along with an automatically created timestamp. You can direct the QR Code to that page and this way you can do what you want.

      1. Hi Kerem. I’m new at this and I understand what you’re saying conceptually. Can you explain a little further how exactly I would structure the QR code? I understand I’d create a code that would navigate to the mobile web page that has the form. How do I tell the QR to fill in the form with the timestamp? Thanks a million. This is really exciting!

        1. Hi Kelly, QR Codes are just shortcuts. You can’t fill out a timestamp in a form with it. That should be done on the server side with a dynamic web language like PHP.

          1. Ok. Sure. That makes sense. I should have asked how do I tell the QR code to fill in the form? I know you have a lot of people you’re communicating with, so if you need to direct me to something to read, that is fine. I so appreciate your help!!

            1. Still, you can’t tell the QR Code to fill in the form. 🙂 You may do something like this though:

              You can encode a URL like “http://example.com/page.php?message=Hello” into your QR Code and when someone goes to that URL, the message “Hello” gets pre-filled into some field. The URL fills the field though, it is not something that the QR Code does. It is again, only a shortcut for this URL.

  4. Hi Kerem. Thank you for this excellent generator! I made a donation (I think and hope). It was a little too quick and I didn’t get a pay pal confirmantion like I expected. Anyway, I am using your generator and it worked like a charm. I’m wondering if it is possible to have a QR code enter text into a spreadsheet or row in a database? I’d like to automate tracking the attendance of our students at the Center for Humane Living. Right now, I’m testing by having it just send me an e-mail from a few test QR codes that will be tailored for each student and dojang location. But it would be best if I could insert a date/timestamp with the student name into a table. Any ideas? Thanks again for the great work!

  5. I just wanted to give you a shout out. I work for an advertising company and repeatedly find myself recommending this generator over many others. Its simple, its precise, and you explain what the hell is going on. keep up the good work! 🙂

  6. Hi Kerem

    Thanks for your reply… I guessed that might be the case.

    I am using Qrafter (and recommending it) but this situation does pose a problem when people using ‘other’ readers get unexpected characters or prefixes that should be hidden. I think that this provides people wanting to use codes in their artwork (like myself) with a dilemma. I can’t put codes on the back of a business card if there is a chance that the person reading the card will think that we have made a mistake with our code generation – it makes us look unprofessional, even though we are trying to do the right thing. Very frustrating!

    Thanks again for replying so quickly, I have emailed ‘RedLabel’ and look forward to their reply.

    Ben

    1. I understand you completely. I have been preaching these standards since 2006 but unfortunately most developers don’t care. The only way to force them is write about their bugs publicly so that some of them can correct their issues. And it’s not about the readers only, many generator sites popped up lately, and most of them do a bad job when it comes to standards. At least my site is very popular in the generator world, so I think that I am able to influence some of those generator developers.

  7. Hi Kerem

    Firstly, thank you for your generator, we are looking at using codes on our business cards.

    Secondly, a question. A QR code (VCard) generated on this site comes up with a result that begins type=internet; before the email address when reading with a code reader app called RedLabel (not just email, other fields also have this kind of prefix e.g. the URLs begin with type=WORK: ) Is this because codes can be incompatible across readers or is their reader doing something wrong?

    Thanks in advance for your reply

    Ben

    1. Hi Ben,

      See my reply to Arnaud just above, like him, you are using an inferior QR Code reader that cannot parse vCards. Also please read the Notes section. Most QR Code reader developers do lousy work and don’t follow necessary standards. If you are using iPhone, I strongly suggest you use Qrafter for standards compatibility.

  8. Hi Kerem,
    thanks for this useful ressource and the great job.
    I created a Vcard 3.0 QRcode and it works fine when flashed with my Iphone. There is however always a “;” that appears just after the organization name, I wonder if there is perhaps a typo in the generated code. Thanks for your input.
    Best regards, Arnaud

  9. Kerem,

    Programin cok harika. Sana bir sorum olacakti. Bu QR codu ile websayfasinda bulunan secure pdf leri linkleyebeilirmiyiz? Yada baska bir deyisle, username and password gerektiren sharepoint ‘e girip pdf sayfasini acabilir miyiz?

    1. Teşekkürler Çağatay,

      QR Code genellikle seni sadece URL’i yazmaktan kurtaracaktır. Bu yüzden direkt olarak pdf’i linklesen de, sanırım dosyayı açmak için öncelikle kullanıcı adı şifre girmen gerekecektir.

  10. 2D Identification server – Not sure if this is the right name for the backend server with database. We are trying to locate a Backend server that can redirect the 2D scan request from the SmartPhone or TouchPad to the backend server and authentication by the server before sending the request to other site or task within the web application that currently we are developing in house.

  11. We are looking at including a QR code in a variety of our materials. Do you have any guidelines for sizing? i.e. what is the best size to ensure the QR code always works? What is the smallest size you can make it and still have it function?
    Many thanks – we will definitely be making a donation!

    1. Hi Jaime,

      Unfortunately there is no standard size for a QR Code to work. If you are going to support only the newest devices like iPhone 4, you can make the code smaller than 1 inch but if you want to support old phones like iPhone 3G, the code must be bigger than or 3 or 4 inches.

      You will need to test your code with different devices.

  12. I’m produced a vCard QR code for my business card. Your generator works great except I’m getting a semicolon after the company name. It was the same using both i-nigma and Qrafter. Do you know where the problem might reside?

    1. i-nigma cannot parse the organization field correctly and you are most probably using the very first version of Qrafter if you are getting that error with it. Because it can parse this field without problems. Please update it to the latest version.

  13. Thanks for all the info awesome! I’ve used i-nigma to scan all my QR Codes and it works well (Nexus S). We are producing QR Code/NFC Tags that can be scanned or tapped by NFC Phones

  14. Hi it is nice!! I am currently use I-nigma and i think it is one of the best!! Very quick, versability and you can use it with more than 500 devices.
    Thank you for your nice and very interestin blog

    1. While i-nigma is really one of the best when it comes to scanning a code, it is not very good at parsing the contents of the codes and it is horrible with user interface design. I think i-nigma is lower in quality when compared to Qrafter on iPhone, but that’s my opinion and it is obviously biased.

  15. any suggestions on how to incorporate logo’s or photo’s inside QR codes.

    what program or service do your reccomend

  16. hello Kerem,

    I generated a QR to a URL using your service-thank you.
    Where would I find reports of people using the QR I generated?

    thank you,
    Ann

    1. Hi Ann,

      You can’t track QR Codes created on this blog. But you can shorten a URL using bit.ly yourself (not using the shortening feature on the generator), then enter that URL to the generator. That way you can track the QR Code.

    1. Depends on the devices you’ll be supporting as scanners. Many new smartphones can scan very small codes down to 1″. You should experiment with the content of the QR Code yourself to find a suitable size.

  17. Hi Karem and All,
    Thanks for designing a usable QR generator!
    I am trying to put QR Code on vCard as vCard format. A webpage suggests that most mobile reader can’t read vCard perfectly – so generate a tinyURL to download the vCard which I didn’t like as user has to click download button in mobile Phone.
    That’s why I liked your generator – the code generated by it – is readable by my scanner(kaywa) – when i point my phone camera to PC screen – but when I finally got it printed on vCard – a size of 1.5 by 1.5 inches – then it is not working! 🙁
    Can someone suggest how can I put a readable – vCard QR code on my vCard – may be some change with error correction or pixels?

    1. That’s all about the quality of the camera of your device. My iPhone 3G cannot scan small codes, while an iPhone 4 or other new device can scan 1″ codes without any problems.

Leave a Reply

Your email address will not be published. Required fields are marked *