The proximity sensor on several iPhone models appears to have been temporarily affected by the iOS 11.3 update released in March this year. The proximity sensor, which is located near the earpiece and the front-facing camera, is supposed to detect when the phone has been placed near a user’s ear so that the screen can be blanked to prevent unwanted touch input. However, after the iOS 11.3 update, some proximity sensors appear to be constantly stuck on, causing the screen to go black even when the phone is not engaged in a call.
I confirmed the issue on my iPhone 7 after trying to figure out why the screen was randomly turning black. You guessed it: I was placing my finger over the proximity sensor by mistake. Upon further investigation, it turned out that I could replicate the strange behavior in any app and even on the home screen.
The Fix: Force Restart
Fortunately, a force restart fixed the proximity sensor issues, even though a regular shutdown/restart did not. To force restart your iPhone, refer to Apple’s help page on the subject:
iPhone X or iPhone 8
Press and quickly release the Volume Up button. Press and quickly release the Volume Down button. Then, press and hold the Side button until you see the Apple logo.
Press and hold both the Side and Volume Down buttons for at least 10 seconds, until you see the Apple logo.
iPhone 6s and older
Press and hold both the Home and the Top (or Side) buttons for at least 10 seconds, until you see the Apple logo.
The Forums Agree
It appears the proximity sensor issue has already made an appearance on the Apple forums: