DEV Community

ziadi lotfi
ziadi lotfi

Posted on • Edited on

Generate Qrcode Using Python

Generate Qrcode using qrcode python library

Image description

1- Import qrcode library

import qrcode
Enter fullscreen mode Exit fullscreen mode

2- Declare url variable

url = "www.dev.to"
Enter fullscreen mode Exit fullscreen mode

3- Generate Qrcode

code = qrcode.make(url)
Enter fullscreen mode Exit fullscreen mode

4- Choose Filename & Save

code.save("my_qrcode")
Enter fullscreen mode Exit fullscreen mode

Top comments (0)