
Security News
OWASP 2025 Top 10 Adds Software Supply Chain Failures, Ranked Top Community Concern
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.
@capacitor-community/privacy-screen
Advanced tools
Capacitor plugin that protects your app from displaying a screenshot in Recents screen/App Switcher.

@capacitor-community/privacy-screen
Capacitor Privacy Screen Plugin
⚡️ Capacitor plugin that protects your app from displaying a screenshot in Recents screen/App Switcher.
On Android, this plugin sets the FLAG_SECURE flag to treat the content of the window as secure, preventing it from appearing in screenshots or from being viewed on non-secure displays.
On iOS, this plugin hides the webview window when the app is no longer active and loses focus (UIApplicationWillResignActiveNotification) so that a gray screen is shown instead.
| Maintainer | GitHub | Social |
|---|---|---|
| Robin Genz | robingenz | @robin_genz |
npm install @capacitor-community/privacy-screen@next
npx cap sync
npm install @capacitor-community/privacy-screen
npx cap sync
On iOS, no further steps are needed.
On Android, register the plugin in your main activity:
import com.getcapacitor.plugin.privacyscreen.PrivacyScreen;
public class MainActivity extends BridgeActivity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
// Initializes the Bridge
this.init(
savedInstanceState,
new ArrayList<Class<? extends Plugin>>() {
{
// Additional plugins you've installed go here
// Ex: add(TotallyAwesomePlugin.class);
add(PrivacyScreen.class);
}
}
);
}
}
No configuration required for this plugin.
The plugin only needs to be installed. The protection is enabled by default. However, you have the option to enable/disable the protection:
import { Plugins } from '@capacitor/core';
import '@capacitor-community/privacy-screen';
const enable = async () => {
await Plugins.PrivacyScreen.enable();
};
const disable = async () => {
await Plugins.PrivacyScreen.disable();
};
enable() => Promise<void>
Enables the privacy screen protection.
Only available for Android and iOS.
Since: 1.1.0
disable() => Promise<void>
Disables the privacy screen protection.
Only available for Android and iOS.
Since: 1.1.0
See CHANGELOG.md.
See LICENSE.
FAQs
Capacitor plugin that protects your app from displaying a screenshot in Recents screen/App Switcher.
We found that @capacitor-community/privacy-screen demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 42 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.

Research
/Security News
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.

Security News
Socket CTO Ahmad Nassri discusses why supply chain attacks now target developer machines and what AI means for the future of enterprise security.