If you have put an old Android phone on a shelf to watch your shop, your gate, or the room where your children sleep, you have already solved the hard problems. The phone records with the screen off, keeps the video on the phone itself, and shows you a live picture in a browser on your own network.
Then a cousin picks it up to see what it is. A customer waiting at the counter taps the screen. A child presses the round button at the bottom, because pressing it is what that button is for. And the job stops.
Nobody attacked your camera. Somebody was curious, and Android did what it is designed to do: it went home.
There is a setting for this. It has been in Android since 2014, it is free, it takes about forty seconds, and in two hundred articles on this blog I have never once written about it. This is that article.
How do you stop someone from closing your phone security camera app?
Short answer: Turn on Android's built-in app pinning — Settings, then Security (or Security & privacy), then App pinning — and pin the camera app before you walk away. Google describes it plainly: "You can pin an app's screen to keep it in view until you unpin it." With the screen pinned, the Home and Overview buttons are hidden and other apps cannot be opened, so a casual tap can no longer stop your recording.
Can you lock an Android phone to one app?
Short answer: Partly. Android has two versions of this. The one you can turn on yourself is screen pinning, and Google states directly that with it "the person using the device can exit the mode whenever they want." The truly locked version is lock task mode, and it requires a device policy controller — an enterprise management setup — which is out of reach on an ordinary phone. Pin the screen for the accidental exit. Do not sell it to yourself as a lock.
That distinction is the whole article, so here it is in Google's own words before anything else. From the lock task mode documentation:
"Lock task mode and screen pinning are sometimes used interchangeably. Screen pinning appears similar (and provides an immersive experience) but the person using the device can exit the mode whenever they want."
Two names, two very different guarantees, and almost everything written about this online blurs them together.
The failure this actually prevents
Be honest about the threat, because the threat is not a burglar. A person who wants to stop your camera and knows how will stop it — hold the power button, or pull the plug out of the wall. Screen pinning does nothing about either, and I am not going to pretend otherwise.
What it is genuinely good at is the failure that actually happens in a house or a shop: somebody touches the phone without meaning to end anything. The nephew checking whether it plays videos. The shop assistant picking it up to see the time. The toddler. Google's own example for the feature is exactly this — "you can pin an app and hand your phone to a friend. With the screen pinned, your friend can use only that app." A mounted camera is a phone you have handed to everyone who walks past it, permanently.
There is a second benefit that surprised me. Google's Android 5.0 notes say that once screen pinning is active, "users cannot see notifications, access other apps, or return to the home screen, until your app exits the mode," and that "the status bar is blank, and user notifications and status information are hidden." I have written a whole article about what a mounted camera phone silently displays to the room — message previews, sender names, calendar entries — and a longer walkthrough of using Private Space to hide the apps behind them. Neither mentions pinning, and pinning does a good part of that job as a side effect of one toggle.
Turning it on, in order
The path has moved between Android versions and manufacturers, so expect to hunt slightly.
- Open Settings. Google's general instructions say Security or Security & location, then Advanced, then App pinning. On newer Pixel devices it is Security & privacy, then More security settings, then App pinning. In 2014 it was Settings, Security, Screen Pinning. If yours is somewhere else again, that is normal — Google's own help page ends with "If you can't find it, get help from your device manufacturer."
- Turn the toggle on. On Pixel Tablet the switch reads Use app pinning; elsewhere, App pinning.
- Open the camera app and get it into the state you want left running. Pinning preserves what is on screen; it does not configure anything for you.
- Open the Overview / Recents screen and pin the app from there.
- Test the exit before you walk away. Google documents three unpin gestures: gesture navigation, "Swipe up and hold"; 2-button navigation, "Touch and hold Back and Home"; 3-button navigation, "Touch and hold Back and Overview."
A tip that costs nothing: do step 5 twice, once with the screen freshly woken. The gesture is unusual enough to forget, and a camera phone is a device you may not touch again for weeks.
The credential prompt, and a contradiction worth knowing about
You would like the phone to demand a PIN before anyone unpins it. That option exists — but whether you get a choice about it is unclear from Google's own documentation, because its two help pages say different things.
The general Android help page states it as automatic:
"When app pinning is on, you need to enter your PIN, pattern, or password before you can unpin."
The Pixel Tablet help page states it as an option you are offered:
"When app pinning is on, you'll see an option to ask for your PIN, pattern, or password before unpinning."
Both are first-party Google pages, they do not agree, and neither quotes the exact wording of the switch. So verify it on your own device rather than trusting either page, or this one. Pin the app, try to unpin it, and see whether you are challenged. If you are not, go back into app pinning settings and look for the toggle. It is the only thing standing between "a curious person cannot casually exit" and "a curious person cannot exit at all."
The stronger version you probably cannot have
Since somebody always asks: yes, Android can genuinely lock a device to one app. It is called lock task mode, and the documentation is clear that it is not for individuals.
"Only apps that have been allowlisted by a device policy controller (DPC) can run when the system is in lock task mode."
With a DPC in place, an administrator gets the controls you actually wanted. They can suppress the menu that appears when you long-press power — "a user typically can't power off the device if you disable this dialog." They can mute and lock the volume. They can make an app the device's home app so "it's launched automatically when the device starts up."
To get there you must establish a device owner, and the documented route runs through adb shell dpm set-device-owner on a device with no accounts on it. That is a factory reset, a computer, a cable and a command line — for a phone that was meant to be the cheap, low-effort option. For a shop owner with one spare handset that is not a realistic path, and I would rather say so than write a tutorial nobody can follow.
So: the weak version is one toggle away, the strong version is behind an enterprise setup. Use the weak version, and know what you have.
What the documentation does not tell you
Six real gaps. I went looking for each in Google's own pages and did not find them.
- Whether pinning survives a reboot is not documented anywhere I can find — not the Android help page, the Pixel page, the lock task guide, the Android 5.0 notes, or the CDD. No Google page says it persists; none says it is cleared. If you live somewhere with regular power cuts, this is the gap that matters most to you, and you can close it yourself in two minutes: pin the app, restart the phone, look. A camera that comes back unpinned after every outage needs somebody to walk over and re-pin it — and a power cut and an internet outage already do very different things to a phone camera.
- What happens when the screen turns off and back on while pinned is not documented either. The nearest statements are about lock task mode, and I will not extrapolate one to the other.
- Whether you can still drag down the notification shade while pinned is not stated for screen pinning. The blank-status-bar language is there; the shade itself is only addressed as something a device policy controller can toggle.
- Nothing addresses incoming calls, in either mode, on any page I read.
- The power button under user screen pinning is never discussed. Everything about suppressing the power menu belongs to the enterprise path.
- The exact on-screen label of the require-a-PIN switch is never quoted — which is precisely why two help pages can contradict each other without either being obviously wrong.
Will your phone even have this?
Almost certainly — and this is the good news if you are running an older or budget handset. Screen pinning arrived in Android 5.0 ("Android 5.0 introduces a new screen pinning API that lets you temporarily restrict users from leaving your task or being interrupted by notifications") and it is not optional for manufacturers. The requirement is still in the Android 16 Compatibility Definition Document:
"MUST implement the screen pinning behavior and provide the user with a settings menu to toggle the feature."
There is a condition attached — it applies to implementations that include the recents navigation key — but in practice, if your phone has a Recents button or gesture, the feature is supposed to be there. A phone from 2016 running a forgotten version of Android has this. No new device, no subscription, no account.
The five-minute version
- Turn on App pinning in Settings (Security, or Security & privacy).
- Open the camera app, get it into the state you want, pin it from Recents.
- Check whether unpinning asks for your PIN. If not, find that option and turn it on.
- Learn the unpin gesture for your navigation mode, and practise it once.
- Test a reboot, because nobody has documented what happens after one.
- Remember what you bought: protection against the accidental exit, not against a person who means it.
Background Camera RemoteStream works on the same principle — an old Android phone recording with the screen off, video kept on the device rather than on somebody's server, and a live view you open in a browser on your own network with nothing to install on the second device. Pinning is a good companion to that, because a camera any passer-by can close is not really unattended. It is on Google Play, and there is more at superfunicular.com.
Further reading
- How to watch your shop with an old Android phone — no internet plan, no subscription, no credit card
- Your camera phone is still signed in: notifications, secondary users and Private Space
- Lock everything except the camera: an Android Private Space walkthrough
- What happens to a phone security camera during a power cut or an internet outage?
Sources
- Android Help, "Pin & unpin screens": https://support.google.com/android/answer/9455138?hl=en
- Pixel Tablet Help, app pinning: https://support.google.com/googlepixeltablet/answer/13592197?hl=en
- Android Developers, "Lock task mode": https://developer.android.com/work/dpc/dedicated-devices/lock-task-mode
- Android Developers, dedicated devices cookbook: https://developer.android.com/work/dpc/dedicated-devices/cookbook
- Android 5.0 platform highlights (screen pinning): https://developer.android.com/about/versions/lollipop/android-5.0
- Android 16 Compatibility Definition Document, section 3.8.3: https://source.android.com/docs/compatibility/16/android-16-cdd
Top comments (0)