1. Open the Settings app on your iPhone.
2. Scroll down and hit "Phone" in Settings.
3. Tap "Silence Unknown Callers" in Phone Settings.
4. Turn the switch next to "Silence Unknown Callers" to "On" in the Silence Unknown Callers settings.
When you get a call from an unknown number, you will not hear a ring or a notification sound. The call will be routed to voicemail, and it will display in the Phone app's recent calls list. If the caller leaves a voicemail, you may still receive a notification.