Showing results for 
Search instead for 
Did you mean: 

Rename a File in Sharepoint

Can you please add the feature "change the name of a file" in the connector as it is posible in oneDrive


Status: New
New Member

Please, add... this is needed.

Frequent Visitor

I'm crying out loud for it.

How can such a simple need can't we achieved in such a complex solution.

Regular Visitor

This is such a simple feature. How is there no way to rename a file? Very irritating.

Frequent Visitor

Why is this still an issue??  This feature request was submitted THREE YEARS AGO.  Get it together Microsoft!

New Member

This would be very helpful.  I found a workaround in copying the contents of a file to the next file, then removing the original.  This doesn't work as straight forward on onenote files, but the built in rename function manually on sharepoint works correctly to rename the onenote files.

Frequent Visitor

Hi @RobertMoriarty , i'd suggest you use the send http request to SharePoint instead (see for an example). That way your file history and created/modified details are preserved.

* edit * Credit where credit is due: @DawgPoundMBA1 submitted the same answer earlier in the thread. I understand the complaints of the other people in this thread regarding the obscure way to do this basic action, but it's doable and without a premium licence at least.

Additional tip: by including the editor property, you can preserve the latest 'modified by' of the item.

Best regards, Marc

Super User

I believe there's an easier HTTP request to rename a file.


Frequent Visitor

@tom_riha, you're to modest 😉

And yeah, you're right. Your posts Update single SharePoint column in Power Automate with HTTP request and Update SharePoint column without new item version in Power Automate should help everyone needing this feature. Cheers!

Power Participant

This is all well and good. @tom_riha & @MarcBoes , but I can't for the life of me get that to work for items placed into the General folder which is a sub-folder of all Documents folder libraries. The IDs are different, and if I'm not mistaken it's dealt with as an entirely different list.


However even if I place the correct list ID for the General folder and use a GUID reference or getbyid, it still won't rename the file. 😞


Ignore me, I was sending the wrong type of HTTP request. This works, but I would guess that you do need to specify the ID (using GetById('INSERT_LIST_ID_HERE')) rather than the Title (using GetByTitle('General')), as it won't recognise 'General'.


Does it work with 'Documents\General' or 'Documents/General' if you do it by name?


OK, I was wrong ... the ID is for any files created in the Documents library ... the 'General' folder (something that will be used a lot if you use Teams) is just another item in the list, and any items in that folder are numbered sequentially with items in the main Documents library. So ... in short ... just use 'Documents'! 😅

Frequent Visitor

@eliotcole , to update an item you don't need to specify the folder. The moment you know either the ListID or the title of the list/library, you can update all items based on the ID regardless of their (sub) folder.

If you need to find out which items/files are in a particular folder first to get to the ID's, then you can get those with 

_api/Web/GetFolderByServerRelativeUrl(<folder url>)?$expand=Files

For example I have a site /sites/dms-kb with a resources folder in the Documents library.




returns the files.

To get the ItemID of the file, you can call something like: 


Note that this method can also be used to find the ListID or title of a library in cases where you only have the URL, for example:




Returns (XML output from the browser):

<d:Name ...">Shared Documents</d:Name>

If that is not what you meant, do let me know!

<edit: never mind, you updated your post while I was typing. This reply is here till I find a way to delete it.>