Optical fingerprint sensor has been provided for security with Nothing Phone 2. Optical fingerprint sensor is a mobile security technology that works by converting the light of your finger.
This is the reason why when you place your finger on the scanner of the phone's screen, the phone lights up. Actually, it scans the 3D image of your finger with the help of light and locks-unlocks the phone.
However, this type of fingerprint sensor does not work properly when the hands are wet or sweaty. Compared to ultrasonic fingerprint sensor, optical fingerprint sensor is cheaper and its accuracy is also less.
(pc amarujala)