SOLVED

Prevent site visitors from accessing documents on a Teams SharePoint site

%3CLINGO-SUB%20id%3D%22lingo-sub-2056708%22%20slang%3D%22en-US%22%3EPrevent%20site%20visitors%20from%20accessing%20documents%20on%20a%20Teams%20SharePoint%20site%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2056708%22%20slang%3D%22en-US%22%3E%3CP%3EHi!%20I%20have%20a%20need%20to%20setup%20Teams%20sites%20where%20visitors%20can%20access%20the%20main%20site%20page%20itself%20but%20not%20any%20documents.%26nbsp%3B%20One%20simple%20solution%20is%20to%20simply%20go%20to%20each%20top%20folder%20for%20each%20Channel%20in%20the%20Team%20(such%20as%20the%20General%20folder)%20and%20hit%20manage%20access%20and%20then%20remove%20Visitors%20form%20this.%20That%20works%20in%20most%20cases%20but%20we%20have%20some%20Teams%20where%20new%20channels%20are%20added%20all%20the%20time%20and%20it%20is%20hard%20to%20remember%20to%20do%20this%20since%20a%20new%20top%20folder%20is%20created%20every%20time%20a%20new%20Teams%20channel%20is%20added.%20So%20we%20are%20looking%20for%20a%20way%20to%20stop%20visitors%20from%20seeing%20documents%20but%20still%20be%20able%20to%20see%20the%20front%20page%20of%20the%20site%20even%20when%20new%20channels%20are%20added.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20tried%20to%20setup%20a%20new%20permission%20and%20a%20new%20group%20with%20this%20permission.%20The%20permissions%20I%20added%20where%20(anything%20less%20than%20this%20does%20not%20allow%20me%20to%20get%20to%20the%20site%20at%20all)%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EUnder%20List%20Permissions%3A%3CBR%20%2F%3E%E2%80%A2%20View%20Items%20-%20View%20items%20in%20lists%20and%20documents%20in%20document%20libraries.%3CBR%20%2F%3EUnder%20Site%20Permissions%3A%3CBR%20%2F%3E%E2%80%A2%20View%20Pages%20-%20View%20pages%20in%20a%20Web%20site.%3CBR%20%2F%3E%E2%80%A2%20Open%20-%20Allows%20users%20to%20open%20a%20Web%20site%2C%20list%2C%20or%20folder%20in%20order%20to%20access%20items%20inside%20that%20container.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThat%20seemed%20to%20work%20at%20least%20for%20existing%20channel%20top%20folders%20but%20the%20second%20I%20added%20a%20new%20channel%2C%20the%20new%20restricted%20visitor%20group%20was%20once%20again%20added%20with%20view%20permissions.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThis%20is%20using%20SharePoint%20online%2C%20moderns%20sites%20where%20all%20sites%20are%20Teams%20sites.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAppreciate%20any%20tips%20on%20how%20to%20accomplish%20this.%26nbsp%3B%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2056708%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EPermissions%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ESharePoint%20Online%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ETeams%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EVisitor%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2058792%22%20slang%3D%22en-US%22%3ERe%3A%20Prevent%20site%20visitors%20from%20accessing%20documents%20on%20a%20Teams%20SharePoint%20site%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2058792%22%20slang%3D%22en-US%22%3EWhile%20I%20don't%20recommend%20to%20change%20the%20permissions%20of%20the%20Teams%20Document%20Library%20or%20the%20channels%20in%20the%20Team%2C%20what%20you%20could%20do%20it's%20to%20break%20inheritance%20in%20the%20Document%20Library%20and%20remove%20from%20there%20the%20Viewers%20group%3C%2FLINGO-BODY%3E
New Contributor

Hi! I have a need to setup Teams sites where visitors can access the main site page itself but not any documents.  One simple solution is to simply go to each top folder for each Channel in the Team (such as the General folder) and hit manage access and then remove Visitors form this. That works in most cases but we have some Teams where new channels are added all the time and it is hard to remember to do this since a new top folder is created every time a new Teams channel is added. So we are looking for a way to stop visitors from seeing documents but still be able to see the front page of the site even when new channels are added.

 

I tried to setup a new permission and a new group with this permission. The permissions I added where (anything less than this does not allow me to get to the site at all)

 

Under List Permissions:
• View Items - View items in lists and documents in document libraries.
Under Site Permissions:
• View Pages - View pages in a Web site.
• Open - Allows users to open a Web site, list, or folder in order to access items inside that container.

 

That seemed to work at least for existing channel top folders but the second I added a new channel, the new restricted visitor group was once again added with view permissions.

 

This is using SharePoint online, moderns sites where all sites are Teams sites.

 

Appreciate any tips on how to accomplish this.  

 

2 Replies
Best Response confirmed by Beau Cameron (MVP)
Solution
While I don't recommend to change the permissions of the Teams Document Library or the channels in the Team, what you could do it's to break inheritance in the Document Library and remove from there the Viewers group