2

I just want to know is there any option to stop taking the screenshot from a mobile view of any web page which is designed using HTML CSS of with a framework like bootstrap?

  • A screenshot comes outside the browser, so I'm not sure how you'd expect to stop it from the web page – VLAZ Mar 14 '19 at 05:55

2 Answers2

5

I’m pretty sure there is no way of doing this. Screenshots are not a function delivered by website, and even not by browser. It’s your mobile function.

It’s the same like you can’t prevent desktop browser to do print screen of your site.

Another thing is that it’s a default behavior and as such it shouldn’t even be modified - it would confuse users.

  • Plenty of native apps prevent screenshots, for example banking apps. This is a valid question and is not comparable with the desktop. – Timar Ivo Batis Apr 27 '21 at 03:00
  • @TimarIvoBatis “plenty of native apps”... But OP is asking about web app, not a native one. – Krzysiek Dróżdż Apr 27 '21 at 04:11
  • 1
    A browser on mobile is a native app, and therefore could have this ability. Just like you can vibrate the phone with navigator.vibrate(pattern). It's not impossible, there's just no API for it. – Timar Ivo Batis Apr 27 '21 at 17:46
  • @TimarIvoBatis yes, browser can have this ability. But OP is not about writing a browser. The question is how can you do that from a web app - and the answer is - you can’t. Of course if you have better answer and know how to do that - feel free to publish your solution - I’ll be glad to learn from you :) – Krzysiek Dróżdż Apr 27 '21 at 17:50
  • @TimarIvoBatis it’s exactly for that reasons. And seriously - if you have better answer - post it. Everyone (including me) will be glad to learn. Have a nice day ;) – Krzysiek Dróżdż Apr 27 '21 at 18:46
1

This would be technically possible see android API: How to prevent Screen Capture in Android

But currently there is no API yet for accessing this through browsers.

Timar Ivo Batis
  • 1,861
  • 17
  • 21