There is a feature in SharePoint Online where you can select a document and choose 'Copy URL' to generate a shareable link to a document.

Unfortunately, by default, SharePoint is configured to make the document open on Office Online when a user clicks this URL. I need a way of creating a URL that opens the document on the user's client, not Office Online.

Does anybody know if this can be achieved? Thanks


If you are just looking to have this functionality within a single document library:

In library settings click on Advanced, you will see : enter image description here

you can set the default behaviour to open in Client application (Word, Excel etc) - I have mine set to open in browser by default.

  • Sorry, I should've made it clearer in my post. I already have this feature enabled which works fine when a user is viewing a document library and clicks on a document. However, if I select the document and choose 'copy URL' to create a shareable link, the link still directs the user to Office Online.
    – Toby
    Dec 6 '18 at 10:35

Ok, no worries.

So the link currently created looks like - https://mysite.sharepoint.com/subsite/dev/Shared%20Documents/file_name.xlsx?d=w732427edb5f64c25bb8422507c5f70ad

You could create a calculated column to strip the url back to -


Losing everything from the ? to the right.

Have you experience of creating calculated columns? Or formula in excel?

You will probably need the calc column to create the url, then another column to hyperlink the Url - which you can then display in the doc lib - when users click on your created link, the document will then open in the relevant application


You can't set Shared Links to open directly in Client Application. You will have to manually create a link in below format and share it to open in client application.

The following will open in the client directly:


This link will prompt user to open in client application:


Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.