I've tried this (very recent) Sharepoint 2013 How to hide Gear Button for non admins without change masterpage and it worked in Classic Experience, but the gear icon is still displayed in the Modern Experience.

I also tried this Hide the gear icon (Site Actions) for all users except Admin and many other solutions online. None of them work.

I'm quite happy using CSS just to hide it and the code from first link works, but for Classic Experience only. I need it working in the Modern Experience.

I use SharePoint Chrome extension to link .js and .css files to SharePoint sites, but Modern Experience sites seem to ignore them.

Why oh why is Site Contents available to all users is beyond me...

To be more specific, I do not want anybody to see this list:

enter image description here

  • 1
    What is the purpose of doing this? Site Contents shows only what they have access to which seems fairly benign.
    – Trevor Seward
    Jun 1 '18 at 19:27
  • Site Contents list shows all lists and libraries. They don't have access to them, but they can still see them. When they go in, it's empty for them, but they can still see a number of items inside each list/library and they can also see column names etc. How can you allow unauthorized users to see all this?
    – Maciek
    Jun 1 '18 at 19:30
  • You'll find that they have Limited Access rights. By default, when you disable inheritance, limited access for the groups that were previously there remains. You have to go and explicitly remove this permission after disabling inheritance.
    – Trevor Seward
    Jun 1 '18 at 19:31
  • I added a picture of Site contents, the list I don't want anyone to see. This user doesn't have access to any of those. Lists, libraries, apps and yet he can still see it. I just want to hide the Gear Icon for non-admin users.
    – Maciek
    Jun 1 '18 at 19:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.