How often do you see that disabled users from active directory appears in SharePoint.
There are scenarios you might observe disable person's details will appears in SharePoint people search, they will still show in the organization chart webpart in my site etc. Why is it so?. You (or) person who has done configuration of the user profile forgot to filter the disabled user accounts from active directory to SharePoint. To avoid the above cases you have to filter the disabled user accounts from Active Directory to SharePoint.
In this post you will learn how to filter user profile information of disabled user accounts from Active Directory to SharePoint.
To filter the disabled user accounts
Go to [Central administration] [application management] [Manage service applications] [User profile service application]
The below Figure will appears.
Click on Configure synchronization connections under Synchronization section of user profile service application.
From the connections you are using click on Edit connection filters menu.
It will open the Edit connection filters screen from that you can see Exclusion filter for users.
In Exclusion filter for users enter the below values.
Attribute : userAccountControls (Select from dropdown)
Operator: Bit on Equal (Select from dropdown)
Filter : 2
Once you enter the required values click on Add button and it will show the below details in Exclusion filter for users section.
Finally click on ok button to submit the Edit connection filters details. Once you are done wait for full synchronization to run or you can forcefully run(In Dev or Test or UAT environments).
Devendra Velegandla is a five-time recipient of Microsoft's Most Valuable Professional (MVP) award (2014-2019) for Office Apps and Services, Office Servers and Services MVP and SharePoint Server. He received the MCC award for his contributions in Microsoft MSDN/TechNet forums. He loves sharing articles, videos, and tutorial on SharePoint and Office 365.