How to copy an existing Document Library in SharePoint Online
One of the long-anticipated features that we recently got in SharePoint Online was the ability to duplicate document libraries. This was always a desired functionality, especially if your library is configured with metadata. Say you created a document library on some SharePoint site, added some metadata columns, set up some views, and now want to replicate this library on the same site or some other sites; you were out of luck. Even though we could copy lists for quite some time, we could not really duplicate document libraries. Not anymore! We can now copy an existing document library in SharePoint Online. So, in today’s post, I will explain the capability and the nuances you must be aware of.
What is a Document Library?
If you are wondering what a Document Library is and how it differs from folders, check out this post.
Lists vs. Libraries
In case you are wondering what the difference is between Libraries and Lists, I also have an article for you as well! By the way, we could copy lists for quite some time; check out this post to learn how to copy Lists.
How to copy an existing Document Library in SharePoint Online
- For this exercise, I will copy this existing document library with a few metadata columns and views configured.
- Ensure you are on a SharePoint site where you want to copy the document library to (you can copy libraries on the same site or from other sites).
- From the SharePoint Site Homepage, click New > Document library
- The pop-up page shows you a few ways to create document libraries. Choose From existing library
- On the next screen, you will see a list of sites you have access to. Choose a site where a document library you want to duplicate resides (it can be the existing site or some other sites), next, choose the document library you would like to duplicate.
- Once you select the document library to duplicate, click Next.
- Give the new document library a name and click Create.
- The library will now be created.
Important Notes:
- The copied document library has no association with the original document library at all
- You can copy a document library from any site you have access to; the original document library does not need to reside on the same site where you are creating a duplicate
- The copied document library does not copy any content (files, folders) from the document library, just the columns and the views!
- In case you are trying to copy a document library from another SharePoint site, and that document library has a Lookup column to some other list or document library on that site, when you duplicate the library, it will also duplicate the associated list (so that the Lookup column will continue to work!!!)
- In some cases, you might get the following error message when copying a document library: This list has a dependency on another list with a template type that is not supported. This error occurs when you enable Audience Targeting on the document library you are trying to duplicate. If you would like to bypass this error message, navigate to the document library you are trying to duplicate and disable Audience Targeting.