I have noticed this new feature in SharePoint Modern Site pages in my O365 SP Online site. Can someone tell me on what basis this page-view is calculated (e.g - weekly, monthly or it shows the total page views since the inception/creation of this modern site page.? Also, I want to hide these from other site users. How can I do so.?

  1. I do not prefer choosing SPFX Application customizer and using CSS to do this. (tried and working)
  2. Though, I am able to remove the "Comment" option by disabling it at edit/publish page level

Refer SS:

Modern Page views

4 Answers 4


In my experience, it shows the total number of page views since page creation. Though, the method to calculate page views is not known to me, so it could be different. Its not stored in any hidden list or something, but in some data store for which we dont have any API yet.

The Social Bar will appear on all modern SharePoint Online pages with the exception of the home page of a site. It will give your users the ability to like a page, see the number of views, likes, and comments on a page, and see the people who have liked a page. This visibility will be available to anyone that has been granted access to view the page.

This is what appeared in the message center.

To disable it at tenant level, you can use below PS command:

Set-SPOTenant -SocialBarOnSitePagesDisabled $true

or using PnP

Set-PnPTenant -SocialBarOnSitePagesDisabled $false

To disable it at site collection level, you can use below PS command:

Set-SPOSite -Identity <site-coll-url> -SocialBarOnSitePagesDisabled $true

You need to ensure that your SPO PowerShell is the latest version or atleast a version after Feb 2018.

Also, looks like it can't be disabled on modern team sites because of a bug on the Microsoft end of things. Works fine on Communication sites.

So, to answer your question:

It will be visible to all users who have read rights on the page. If you want to hide it for certain group, use application customizer (not recommended though because Microsoft controls the rendering and if the DOM structure changes, you will have to modify the code, better disable it for all users or show it to all users IMHO)

  • Is this based on User permission level?I mean admin should able to create but not other user like read/visitors.
    – G.Srinivas
    Commented Jan 3, 2019 at 11:48
  • @G.Srinivas can you elaborate ? what do you mean by admin should be able to create ? Commented Jan 3, 2019 at 12:41
  • Sure, if I use Set-SPOTenant -SocialBarOnSitePagesDisabled $true and disabled that option. so will it be disabled for every one(including admin and normal user) or can be specified for group of people/users?
    – G.Srinivas
    Commented Jan 4, 2019 at 7:47
  • 1
    It will be disabled for everyone including admin and normal users. We cant specify it for a group of people/users. Commented Jan 4, 2019 at 7:50
  • Thanks @Gautham Sheth for clarifying the confusion
    – G.Srinivas
    Commented Jan 4, 2019 at 8:43

Using PnP both

Set-PnPTenant -SocialBarOnSitePagesDisabled $false 


Set-PnPSite -SocialBarOnSitePagesDisabled $false 


Set-SPOSite -Identity <site-coll-url> -SocialBarOnSitePagesDisabled $true

Does Not work for my modern communication sites


Install latest Microsoft Online Management shell version in your machine and run the below script which will address this issue.

#Set Parameters
$SiteURL = "https://yourtenant.sharepoint.com/sites/sitecollectionName"
#Connect to SharePoint Online
Connect-SPOService -Url $AdminCenterURL -Credential (Get-Credential)
#Disable Social Bar on Site Pages
Set-SPOSite -Identity $SiteURL -SocialBarOnSitePagesDisabled $true

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.