This add-on adds a command that encodes DDEV URLs into QR codes.
It uses qrencode to parse a URL string into a QR code that is displayed in the terminal.
This helps reduce errors and frustration when entering URLs on portable devices.
ddev add-on get ddev/ddev-qr
ddev restart
After installation, make sure to commit the .ddev directory to version control.
| Command | Description |
|---|---|
ddev qr |
Encodes the primary website. Eg. https://example.ddev.site. Shorthand for ddev qr https. |
ddev qr https |
Encodes the HTTPS version of the primary website. Eg. https://example.ddev.site. |
ddev qr http |
Encodes the HTTP version of the primary website. Eg. http://example.ddev.site. |
ddev qr share |
Tries to find the share tunnel and encodes the random address. |
ddev qr _STRING_ |
Encodes the value of _STRING_. |
Note: Using ddev qr or ddev qr https inside a Gitpod environment will encode the Gitpod-routed DDEV URL instead.
A QR code is a two-dimensional barcode that can store a string of information such as a URL. You can use a QR reader, such as the camera in you mobile phone, to read the image. In the case of a URL, a mobile phone can then visit the URL.
Below is QR code with https://ddev.com encoded.

See Scan QR codes on Camera from Google. See Scan a QR code with your iPhone, iPad, or iPod touch.
Initially, this addon was created for use with ddev share which (currently) uses ngrok.
When using the free tier service, ngrok generates a random string address to access your website:
Eg. https://124-5da4-96-37-190.ngrok-free.app
This is great but it’s not so fun typing that string on a small keyboard. Instead:
ddev shareddev qr shareSimilarly, when using DDEV in Gitpod, DDEV defers to Gitpod’s routing system that also generates random complex strings.
Using ddev qr or ddev qr https inside a Gitpod environment will encode the Gitpod-routed DDEV URL instead. Eg. https://ddev-qrdemo-cksfu15uj8u4.ws-us131.gitpod.io/
PR are welcome, especially if they contain working tests.
Contributed and maintained by @tyler36