19

The closest I've gotten is from blockchain.info

https://blockchain.info/qr?data=1Agb153xWsbqS9vt8gP4vBFKHkAchLMdSX&size=200

I can't find any documentation for other parameters like 'amount' though?

I did find a service that does a generate a QR code with an amount. I just have never heard of them before (trust?). And am not sure what to put for 'error correction level' or 'code square size' given this code will be displayed on a website.

schulwitz
  • 1,651
  • 1
  • 13
  • 19
magician11
  • 4,234
  • 6
  • 24
  • 39
  • 4
    Very frustrating that this was 'closed', especially with 25k views. To future readers, the industry standard format for bitcoin QR codes is the following: `bitcoin:
    ?amount=&label=
    – Albert Renshaw Jun 03 '20 at 04:06

3 Answers3

20

There are many ways you can generate a QR code!

IMO, the most trusted way to generate a QR code is through google!

You can simply make an tag with this link:

https://chart.googleapis.com/chart?chs=250x250&cht=qr&chl= 12kQMUkB9QJu9X5JP9H9M2qMUmrGtDakkV

Im not sure what you mean by "trust". You dont really need to worry about trust since these are just the public keys, and not the private keys.

I hope this helps! (My BTC address is in the QR code!)

nahtnam
  • 2,659
  • 1
  • 18
  • 31
  • Yes you're absolutely right about the key just being public. And there is the potential of the 3rd party encoding another address. So something like Google API sounds pretty solid :) Do you know how to also encode the amount? or label/message info? – magician11 Aug 18 '14 at 12:30
  • 4
    A mailicious code generator may display their own codes instead of yours to collect money. So, trust isn't overrated here :-) – mixdev May 25 '17 at 00:35
  • 2
    Talking about the trust please avoid https://www.bitcoinqrcodemaker.com as much as possible, I just got scammed of $320. before I stumbled on this forum post https://bitcointalk.org/index.php?topic=5091695.0 – electrode Apr 12 '20 at 09:25
19

I use GoogleApi to generate QR codes for bitcoin and altcoins

The syntax is a bit tricky since the "data" portion (chl=*), is itself urlencoded (use %26 instead of &):

https://chart.googleapis.com/chart?chs=225x225&chld=L|2&cht=qr&chl=bitcoin:1MoLoCh1srp6jjQgPmwSf5Be5PU98NJHgx?amount=.01%26label=Moloch.net%26message=Donation

You can make a QR code for other altcoins by changing the chl=bitcoin:1(...) to chl=litecoin:L(...), etc

I made a multi-coin QR code generator for my website with all the available options:

http://resources.moloch.net/qr-generator

The only thing Google is missing, is to verify the address is legitimate (and not a typo), which my api handles seperately

Moloch
  • 191
  • 1
  • 3
4

You can generate a QR code without using a third party using the jQuery QRCode plugin here: https://larsjung.de/jquery-qrcode/

e.g. http://www.numberfacts.com/1Agb153xWsbqS9vt8gP4vBFKHkAchLMdSX

<div id="qrcode"><a href="bitcoin:1Agb153xWsbqS9vt8gP4vBFKHkAchLMdSX?amount=1"></a></div>

<script>
$(function() {
    $('#qrcode a').qrcode({ 
        render: 'image',
        text: "1Agb153xWsbqS9vt8gP4vBFKHkAchLMdSX",
        ecLevel: 'L',
        size: "203"
    });
});
</script>
Chris Wheeler
  • 1,623
  • 1
  • 11
  • 18