To connect a Copilot Studio agent to SharePoint, open the agent, select Add knowledge, choose SharePoint in the Featured section, paste the site or folder URL, give the source a name and a description, and select Add to agent. The agent then answers from that site on behalf of the person asking, so it only returns content they could already open.
I recorded the video above in November 2023, when these were still called “copilots”. Back then, before the agent could read anything, I had to register an app in Microsoft Entra ID, add the Sites.Read.All and Files.Read.All scopes and paste a client ID and secret into the security settings. New agents use Authenticate with Microsoft by default, so none of that is needed for an agent people use in Teams or Microsoft Copilot. The steps below are the current ones.
Before you start
- Access to Copilot Studio. Copilot Studio is included for users with a Microsoft 365 Copilot licence. Without one, your organisation needs Copilot Credits or pay-as-you-go billing set up. A trial lets you build and test, but not publish.
- Read access for the people who’ll use it. If someone can’t open a document, the agent won’t answer from it.
- The right content. The SharePoint source reads Word, PowerPoint and PDF files and modern pages. Classic ASPX pages and modern pages with SPFx components aren’t used, and encrypted files (a sensitivity label that applies encryption, or a password) can show as Ready and still return nothing.
- Files under 7 MB, unless you’re licensed. If the agent’s maker has no Microsoft 365 Copilot licence in the same tenant, answers only use files under 7 MB. With one, and Tenant graph grounding with semantic search turned on, files up to 200 MB work.
How do you add SharePoint knowledge to a Copilot Studio agent?
- Go to copilotstudio.microsoft.com and open your agent, or describe a new one on the Home page and let Copilot Studio draft it.
- On the Overview or Knowledge page, select Add knowledge.
- In the Featured section, select SharePoint. The second SharePoint option, under Upload file, is for picking individual files, folders or lists.
- Paste the URL of the site, library or folder. Put each extra URL on its own line with Shift + Enter. An agent using generative orchestration can have up to 25.
- Add a name and a detailed description. The agent uses the description to decide which source fits a question, so say what’s in it: “HR policies: leave, mobile phones, working from home, COVID-19”.
- Select Add to agent, then ask a few questions in the test pane and open the citations to check where each answer came from.
The agent searches the URL you register and everything under it, never a parent site or a sibling folder. In 2023 I couldn’t paste a SharePoint URL more than two levels deep. Today you can point it at a single library or folder, which is how I’d scope it.
In my demo, asked for the types of leave, the agent listed them with a citation that opened the leave policy, a Word document. A question about the COVID-19 policy came back from a SharePoint page, and one about the XT1000 test plan on a second registered site cited a PDF in that site’s invoices library.
Part one added a public website and an uploaded Word document through the same Add knowledge dialog. An upload is a copy, though. For anything that changes, point the agent at SharePoint so it reads the current version.
How do you publish the agent to Teams and Microsoft Copilot?
- Select Publish, then Publish again to confirm.
- Share the agent with the people or security group who’ll use it. Without that, someone can install it and still not be able to chat with it.
- Select Channels, then Teams and Microsoft Copilot, then Add channel.
- Under Availability options, copy the link for a small group, or submit the agent for admin approval to list it for everyone in your organisation.
Start with a SharePoint agent, and move to Copilot Studio when the job outgrows it
Most SharePoint question-and-answer agents don’t need Copilot Studio at all. If a team wants answers from one site or library, a SharePoint agent does it in a few minutes from the library itself, which I walk through in building a Copilot agent grounded in a SharePoint library, and the team can @mention it in their channel (using a SharePoint agent in Microsoft Teams). If the agent is for you or a few colleagues and needs to follow a method, Agent Builder covers it, and skills in Agent Builder let one agent carry several jobs.
Don’t get me wrong, Copilot Studio is great, and I reach for it when the agent has to do more than answer: triggers, actions, connectors to systems outside Microsoft 365, multi-step flows and approvals, separate development and production environments, and an admin approval step before anything is listed for everyone. If you start in Agent Builder and hit those limits, you can copy the agent into Copilot Studio rather than rebuild it.
Whichever tool you use, the agent inherits every permission and content problem the site already has. A site where HR drafts sit next to approved policies will get drafts quoted back as policy, so register only the library that holds the approved ones. Under the source’s Advanced settings you can also filter on Title, Author, Modified by or Modified on, for example to leave out anything nobody has touched in two years.
What to watch for
- Teams group chats and channels. SharePoint answers work in a one-to-one chat with the agent. Microsoft says group chats and channel messages aren’t supported yet.
- Questions that name a file. “What does leave-policy.docx say about carers leave?” can’t be answered. Ask about the topic instead.
- Questions about the library itself. The agent can’t list or count files, or filter on column values. Use Copilot in SharePoint on the library for that.
- Renamed sites and folders. Renaming the location can break the source. Update it with the new URL.
- Restricted SharePoint Search. If your admin has turned it on, SharePoint knowledge is blocked.
Frequently asked questions
Do I still need an app registration to connect Copilot Studio to SharePoint? Not for most agents. Authenticate with Microsoft works in Teams, Power Apps and Microsoft Copilot without setup. You only need an Entra ID app registration with Sites.Read.All and Files.Read.All if you choose manual authentication, for example for an agent on your own website.
Can a Copilot Studio agent show people SharePoint content they can’t access? No. Calls to SharePoint are made on behalf of the person chatting, who needs at least Read permission, and sensitivity labels are respected. The scopes in a manual app registration don’t raise anyone’s permissions either.
Can a Copilot Studio agent answer from SharePoint lists? Yes. Under Upload file, select SharePoint, then Browse items to pick lists. An agent supports up to 15 lists, and queries only return data from the first 2,048 rows, so keep lists used as knowledge focused.
Why does my Copilot Studio agent say it has no response for a SharePoint question? Check, in this order: whether the person can open the file, whether the file is over 7 MB and the maker has no Microsoft 365 Copilot licence, whether a sensitivity label encrypts it, and whether the content is on a classic page.