We recently received a new request from a customer for a SharePoint phone book. The customer would like to display the users of Active Directory groups and security groups. The customer wants to display a user’s information, such as job description, telephone number, e-mail address and more. In this blog post, we would like to give you insights into the development of this SharePoint phone book.

Default SharePoint People Web Part vs. our SharePoint Phone Book Web Part

In SharePoint Online there is a Default People Web Part, which can also display user information. However, the customer would have to add each user manually. Also if the users of a group change, this must be done manually. In order to make the effort here as low as possible, the customer had the requirement to automatically display all users of a configured Active Directory group or security groups.

We have implemented the SharePoint phone book using an SPFx Web Part. An admin can configure the groups in the Web Part properties.

SharePoint Telefonbuch: Webpart Einstellungen

We read the user information through the Graph API and display it in our Web Part. When hovering a user, the component displays the user information in a pop-up. This functionality is the same as the Default SharePoint People Web Part.

SharePoint Phone Book: User Information

User sorting via drag & drop

Another customer requirement for the SharePoint phone book was to sort users within a group. We have implemented this sorting by drag & drop functionality. If the page is in edit mode, the drag & drop of the users becomes active. The admin then has the option to sort the users in the desired order.

SharePoint Telefonbuch: Benutzer Sortierung

We store the order of the users of the groups in a config file on SharePoint. When the page loads, we read the order of the users from the config file and sort the users by it.

    "groups": [ 
            "title": "Test",
            "orderedUserIds: [

Have we aroused your interest and would you like more information about our phone book web part? Then feel free to contact us. You can also subscribe to our newsletter if you want to be the first to be informed about news:


Never miss any offers or innovations?

Sign up for our newsletter and be the first to learn about exciting new products and topics around Microsoft SharePoint, Teams, and Co.

You can unsubscribe at any time. Your data will only be used to send our newsletter and will not be passed on to third parties. Additional information on the protection of your data can be found in our privacy policy.