Undocumented sharepoint site url limitation?

Copper Contributor

Hey Community,

 

We came across a, for us, previously unknown limitation of Sharepoint when troubleshooting a solution that had failed for one of our customer.

Background, way back we built an app for automatically creating teams from a template team and adding folders and files to it for consistens in their project managment. Works fine.

Then we got a fail notification that something had gone wrong and at the outset we couldn't really see what was wrong. Then after a little investigation we noticed that when creating the team in Power Automate, the associated sharepoint site URL was missing parts of the team name at the end, so the flow couldn't find it when trying to create the folder structure. Looking closer it appears that the Sharepoint site base URL is being capped att 100 characters (https://domain.sharepoint.sites/sitename)

So, if the Power Automate flow was instructed to create a team with the name: 
"This_is_a_ridicoulsy_long_name_to_set_on_a_team_no_matter_the_reason" it would do so and create the team with the full name, and it would also give the same name to the Sharepoint Site home page.

 

However, the Url for the site would be capped at 100, so it would be: 
"https://domain.sharepoint.com/sites/this_is_a_ridicoulsy_long_name_to_set_on_a_team_no_matter_the_re"
Rather than the inputted:
"https://domain.sharepoint.com/sites/this_is_a_ridicoulsy_long_name_to_set_on_a_team_no_matter_the_reason"

I am mainly curious if there are others that have experienced this limitation? It have been unable to find any documentation on it, and even if i can agree that sites shouldn't have that long name, it would be nice to know if there is a hard cap to take ino account in soultions one builds 😉


(and yes, we are aware that the are better ways to build this kind of solutions nowadays, but it is old and that is how we did it back then ;))

1 Reply

Yeah this limit has always existed, the maximum length for a SharePoint site URL is 400 characters, but this limit includes the entire URL path, not just the base URL which is 100 characters.

 

So for SharePoint Online, the The URI path for all files and folders can be no more than 400 characters (and no more than 400 characters for a single file or folder name in the URL).