How to make a QR code for a document

Somebody scans a code on a printed sheet and is asked to request access to a file in your drive.

A code on a printed sheet is scanned by somebody standing somewhere, usually in a hurry. Everything about the destination should assume that.

Pointing it at a document in a drive fails that test twice.

A scanned code landing on a request-access screen. (Illustration.)
A scanned code landing on a request-access screen. (Illustration.)

This guide covers the two failures, what to point at instead, and testing.

Failure one: the permission screen

Drive sharing defaults to restricted. A code pointing at a restricted document produces a request-access screen for everyone who scans it.

They then either request access, which arrives in your inbox at an unpredictable time, or they assume the code is broken.

Changing the sharing setting fixes this and it has to be remembered every time, per document, which is exactly the kind of step that gets missed when printing is involved.

Failure two: the download

Even with sharing open, a document opened from a code on a phone opens in the Docs interface or offers a separate application.

The person is standing at a poster, in a corridor, at a counter. Some of them simply stop.

The code was supposed to remove steps and it added two.

Code to a drive document Code to a page
Permission screen Often No
Opens as a plain page No Yes
Needs the Docs interface Yes No
Content can change after printing Only same doc Yes
Needs an account Sometimes No

Point it at a page

Publish the content at an address you control, and put that address in the code.

The scanner sees the content immediately, at a size their phone can read, with no account and no download. It works identically for everyone regardless of what they have installed.

And because the address is permanent, the content behind it can be replaced whenever it changes. The printed code never needs regenerating.

That last point is what makes printing worthwhile at all. A code that is fixed to a specific document is a code that has to be reprinted whenever the document is revised.

Test it properly

Scan your own code on a phone that is not signed in to your account.

Your own session has access to everything, which hides every permission problem that a stranger will hit. A private browsing window on a desktop does the same job for a link.

This takes thirty seconds and it is the only test that reflects what the person scanning will experience.

A printed sheet with a code and the address in text beneath it.
A printed sheet with a code and the address in text beneath it.

One line of text under the code.

Some cameras do not scan. Some people are holding a laptop. Some codes fail in poor light or on a dirty screen.

Keep it short enough to type, which is another argument for naming the address after the content rather than after a date or a version.

Closely related: How to make a QR code you can change later, and How to turn a PDF into a QR code for the adjacent problem.

Put it at an address

Stop pointing printed codes at drive documents, publish the content at a permanent address, test the scan while signed out, print the address as text underneath, and change what is behind the address rather than the code.

Then the person standing at the poster reads it in one tap.

Questions people ask

Why does the scanned code ask for access?

Because the document sharing setting is restricted, which is the default. The code works; the destination refuses the person holding the phone.

What happens on a phone even when access is open?

The document opens in the Docs interface or offers the Docs app, rather than as a plain page sized for the phone.

What should a printed code point at?

A page at an address you control, showing the content. No permission, no download, no application, and it renders at whatever size their phone is.

Can the destination change after printing?

Only if the code points at a permanent address. A code containing a document link is fixed to that document, so a new version saved as a new file means a reprint.

Should the address be printed as text too?

Yes. Some cameras will not scan, some people are holding a laptop, and one line of text removes the whole failure.

Keep reading