I have a requirement to hide the Gear icon (settings icon) for the “modern look” SharePoint collection for all pages to the users who have "Read" access.

Can any one help how to do the same?


  • For this you have to perform DOM manipulation using CSS in SPFx app customizer (which is not recommended by Microsoft or may break in future if they change css classes). May I ask what is the purpose of doing this? Site Settings will only show users what they have access to, which seems OK. Commented Jan 15, 2021 at 12:41
  • Basically I need to hide the "Site Contents" option from Gear icon for Read access users, to stop seeing the site content data. I can do it by creating custom permissions group and add users to that group to disable the site content, but they are not able to see the docs who has read access, so trying to hide the Gear Icon itself. My ideal retirement is to hide "site contents" option.
    – taruki_MS
    Commented Jan 15, 2021 at 12:52

1 Answer 1


Per my understanding, under normal circumstances modern experience has many restrictions. It is not supported to add .js globally to hide the gear icon in modern experience.

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.