How to lock and unlock iPhone(real device) using appium?

Hello , I am new to appium. I am trying to unlock my iOS device using passcode before I begins my tests and at the end of the test I would like to lock the screen through code… is there anyone can help me with this and let me know how we can do this?

Hi all,

This feature is really important, please can you implement it ?

With Android we can do it, please do the same with IOS.

Thank you in advance.

Currently it is only possible to lock/unlock the iOS device’s screen if it is a simple “swipe” lock screen. Passcode or biometric lock types cannot be handled automatically.


Thank you for your reply.

Do you know if this will be implemented in the future ?

There’s no way to do that unless Apple provides a corresponding API