iOS: Prevent Screenshot Or Prevent Record Screen

Tram Ho

I. The problem

Our team encountered a problem is how to prevent users from taking screenshots or recording videos on iOS. Of course, it eliminates cases like using another camera to shoot or take pictures. After a bit of research, my group came to this conclusion. Of course, if anyone has a solution, our group wants to absorb it.

II. Block screenshots

At the present time, our team found out that the result is almost 100% unable to stop the screenshot on iOS.
The team has devised some methods or has tried many manuals based on the documentation but still failed.

1. allowScreenShot
(page 73)

Our team tried it and didn’t see results.

2. Retouch the image after taking it

Use userDidTakeScreenshotNotification and PHPhotoLibrary notifications.

  • Use observer to capture event, after taking picture.
  • After shooting, use PHPhotoLibrary, to proceed to access the photo to change the image just taken.


  • It is possible to change the image just taken but the app always displays an alert confirm. So this is not 100% satisfactory.

III. Block filming

1. capturedDidChangeNotification

Use notification capturedDidChangeNotification and UIScreen.main.isCaptured. Note that only applies from iOS 11 and above.

The result: based on those events we can process the processing of sensitive information. Although it is not possible as Netfix or HBO, it is still considered to be acceptable.

2. FairPlay Streaming


Secure the delivery of streaming media to devices through the HTTP Live Streaming (HLS) protocol. Using FairPlay Streaming (FPS) technology, content providers, encoding vendors, and delivery networks can encrypt content, securely exchange keys, and protect playback on iOS, tvOS, and macOS.

This SDK, my team has not had the opportunity to test, but according to research, it seems to only apply to video streaming and need to contact Apple for Apple favor.

IV. Other

In addition to the above, the team also has research at . Check out the demo it looks. However, it seems one thing my team does not trust this SDK very much. Because all blog posts from 2018 and earlier, no technology companies use, no public Price and also find out on . Someone commented that, it also uses FairPlay Streaming.

V. Conclusion

The group only made blocking screen rotation, while blocking taking pictures almost gave up on iOS. It is difficult for iOS but Android seems to be more advantageous with support from API 1.

Some sources:

Share the news now

Source : Viblo