Last year it was announced % and # support for file and folder names in Sharepoint Online, according to this link:

https://techcommunity.microsoft.com/t5/SharePoint-Blog/New-support-for-and-in- SharePoint-Online-and-OneDrive-for/ba-p/60357

To verify that you have this feature enabled you run (using latest Sharepoint Online Management module) get-spotenant |ft special and it should display: SpecialCharactersStateInFileFolderNames : Allowed.

I have this setup on my tenant, and I created a Sharepoint Team Site, from the interface: Create Site.

I then proceeded to create some folders named "Folder%", "Folder#", and put some files inside: "test%.txt", "test#.txt".

By going to 'Document' on the left menu, I can browse the folders without problems and view the contents of the files.

If I try to go to the same place, but using the web part "Document library" that's on the right side of the page, when we click 'Home'. It shows the folders and I can navigate to them, but can't open the files, I have the following error : enter image description here

enter image description here

This explains the setup:

Is that the web-part does not behave the same as the Documents interface ? I could not find any document in Microsoft's site.

  • If you think my answer is helpful, please "accept" this answer. May 14, 2018 at 1:28

1 Answer 1


I have reproduced your issue in my SharePoint Online site.

The folder name is “Folder 2%”

The path of file opened from the library directly (the file is open successfully):


The path of file opened from the Document Library web part (400 Bad Request – Invalid URL error):


I found that the “%” in the folder name “Folder 2%” was not converted to “%25” in the path of file opened from the Document Library web part.

Then, I checked it link path using F12.

In the library, it shows:

<a data-automationid="FieldRenderer-name" data-selection-invoke="true" class="ms-Link nameField_a8dbdc8d root-75" href="#id=%2Fsites%2F<site>%2Flib01%2FFolder%202%25%2FForm1%5FView%201%2Epdf&amp;parent=%2Fsites%2F<site>%2Flib01%2FFolder%202%25" tabindex="-1">Form1_View 1.pdf</a> 

enter image description here

In the Document Library web part, it is

<a data-automationid="FieldRenderer-name" data-selection-invoke="true" class="ms-Link nameField_8c2b74bf root-81" href="/sites/<site>/lib01/Folder 2%/Form1_View 1.pdf" title="Form1_View 1.pdf" tabindex="-1">Form1_View 1.pdf</a> 

enter image description here

The links are different.

The cause is it does not convert the “#” and “%” to “%25” and “%23”.

As the Document Library web part is a preview modern web part, you can submit a feedback to SharePoint UserVoice (https://sharepoint.uservoice.com/).

As an alternative, you can use Embed web part. Put the address of your library into the Embed textbox, it will display the library view (not whole page) from this address.

  • Hi JoannaW, a lot of thanks for the answer !! and the time you took for it. I apologize for not responding before to your kind comment. It seems that it's pretty much what you tested. Thanks Sep 20, 2018 at 3:40

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.