What is the cleanest and suggested way to add files to the _layouts folder across multiple web frontends for a SharePoint 2016 on-premise installation?

1 Answer 1


This is a personal opinion, but in my opinion the cleanest way is a "don't".

If you have read this post (CSS Files in _Layouts or Document Library?), and you still want to continue on this journey, storing the files would be effortless and equally functional regardless of the way of accessing method when adding the files to the SharePoint installation's path.

  • 2
    Agreed. Updating files in _layouts is pain as you need to either always push them via WSP, or manually updating the files on all servers. I prefer single folder in /_catalogs/masterpage/XYZ under which you gather all files. Only exception with using _layouts woul perhaps be if you have many web applications with different sets of permissions and you'd like to use some common files in all of them.
    – Jussi Palo
    Commented May 29, 2017 at 9:46
  • The problem I face is, that I need to have a central place for a JSLink file. As we have about 4k Site Collections it is not a good option to upload it to every document library. As JSLink requires a token (like ~layouts) in its URL I thought it might be a idea to store them in there. Otherwise I agree with both of you and dislike this approach, but for me this seems to be the only available option.
    – kekub
    Commented May 29, 2017 at 14:52
  • See also sharepoint.stackexchange.com/questions/216345/… for the reasons behind.
    – kekub
    Commented May 29, 2017 at 14:53

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.