Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I just found out that you can add a geographic component to a QR code.

I also just found you can create one on the Google Chart API using this:,-97.6

That creates me a QR code that looks like this:

enter image description here

So far, so good. And when I read that back on my iPhone using the QR Code Reader app, it sends me to a Google map in the correct location (Austin, TX).

The thing is, the string used to create this uses lat/long. If I wrote the same data to a KML file it would expect long/lat.

So the question is, what spec do I use for QR codes:

  1. Is the QR spec actually lat/long?
  2. Is the Google Chart API getting it mixed up?
  3. Is the QR reader app getting it wrong?

My money is on the QR reader messing up - but I'm not sure. Does anyone have a definitive answer?

share|improve this question
up vote 4 down vote accepted

If it works, then I'm not sure how anything can be messed up! But I think I know what you mean.

The main issue is that QR encodes text, and that's it. How an application interprets that text is the key. The ZXing API for Android briefly lists "Geographic information" encoding as lat/long, and this is confirmed when I scan the QR you provided - it takes me to Austin, Texas.

I've poked around a little (but not exhaustively) and I can find no documentation on it apart from the link above - all other results ultimately lead to that page. A bit more searching may turn up a mailing list or forum discussion where the original spec was discussed.

So the upshot is, as far as geo QR codes go, lat/long is the "standard" and I would be surprised if it ever changed from that in the future. I could envisage another encoding using a different tag that was long/lat, indeed it's flexible enough for you to develop it for your application, but you'd really have to make people aware of it if you want other applications to use it.

Here's a Google Chart QR code with an example of a long/lat encoding, note the lonlat tag is one of my own invention:,30.3

enter image description here

As expected, my Android phone recognises it as a URI, but doesn't know what to do with it.

share|improve this answer
Thanks. I guess the question boiled down to: is Lat/Long the standard for QR? I just didn't trust the QR reader I have and wanted some sort of confirmation. Seems you have answered that for me. – Mark Ireland Jul 5 '11 at 15:20

For Google Maps the URL can be parsed using

enter image description here

Adding KML

For KML is has is be public and read through Google Servers for validation to generate the QR code.

enter image description here

Created using the new Chart Wizard

share|improve this answer
Wow. That wasn't really what I was asking, but that's very interesting and something I hadn't thought about. Thanks! – Mark Ireland Jul 5 '11 at 15:22

Using ZXing Generator where you choose the Lat, Long or click the map, I see the same result on the chart API: according to the ZXing wiki Geographic information:

For example, to encode the Google's New York office, which is at 40.71872 deg N latitude, 73.98905 deg W longitude, at a point 100 meters above the office, one would encode "geo:40.71872,-73.98905,100".

share|improve this answer
Useful generator. fyi the one I was also looking at was: – Mark Ireland Jul 5 '11 at 15:26

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.