As a community contributor, I regularly write blog posts based on my real-time experience from client projects and from working on our internal products. Sometimes I write a completely new blog post, and sometimes I update an existing post with new learning and practical experience.
Before writing or modifying a post on SPGuides or EnjoySharePoint, I always need to check whether a similar post already exists. This includes checking the post title, publish date, and the topics already covered. Doing this manually by searching on multiple websites takes a lot of time, especially when I am working on multiple tasks in a client project.
So, I wanted a simple solution where I can just provide a topic name, and the system will:
- Check whether the post already exists or not
- Give me the post link
- Show the publication date
- List the topics covered in that post
While searching for a solution, I discovered that we can build this using Copilot Studio. However, deploying a Copilot Studio solution requires additional licensing. After further research, I found that we can create a custom agent directly in Microsoft 365 Copilot (Agent Store) without extra complexity.
The best part is that this agent can be shared with:
- All users in the organization, or
- Specific users or teams
In this tutorial, I will show you how to create a custom search agent in Microsoft 365 Copilot using Teams. I will also explain how to share this agent with your colleagues.
Create a Custom Agent in Microsoft 365 Copilot
In this example, I will create the same custom agent that I explained in the previous section. If you have a different scenario, you can follow the same steps and customize the agent based on your requirements.
To create the custom agent, follow the steps below.
- In your browser, search m365 Copilot. Sign in using your Microsoft 365 account.

Or you can open Microsoft Teams. From the left menu, select Microsoft 365 Copilot.

- Then click New Agent/Create Agent. Here you can see two options: Describe and Configure.

For this example, I am configuring. You can describe, or, if you prefer, try the predefined agent.
- Then provide the agent name and description:
- Name: Blog Post Search Agent
- Description:
This agent helps you check whether a blog post already exists on SPGuides or EnjoySharePoint.
You just need to provide a post title or topic name, and the agent will search these websites and return the post details, including the post link, publish date, and topics covered.

Then you can see the name and description will reflect on the right side of the screen.
- Next, add the Instructions. Instructions define how the agent should behave, what input it should take from the user, and how it should generate the output.
Purpose of this agent
You are a content search assistant. Your job is to check whether a specific blog post exists on selected websites and return clear details about it.
What the agent should do
When a user provides a post name or post title, follow these steps:
1. Search for the post only on the following websites:
spguides.com
enjoysharepoint.com
2. Check whether the given post name exists on either of these websites.
3. If the post is found, do the following:
Confirm clearly that the post exists
Provide the full post URL (clickable link)
Show the post publish date
List the main topics or key points covered in the post
4. If the post is not found, do the following:
Clearly say that the post does not exist on the searched websites
Suggest checking the post title spelling or trying a related keyword
Response style guidelines
Use simple and clear English
Be short, accurate, and well-structured
Use bullet points where helpful
Do not guess or make up information
Only return information that is actually found on the websites
Limitations
Do not search outside the two specified websites
Do not create content summaries if the post does not exist

Next, we need to add the Knowledge section. Knowledge sources indicate where the agent is allowed to search for information.
- In this example, I am adding two specific websites as knowledge sources because I want the agent to search only these sites.

After adding the URLs, make sure Search all websites is turned OFF. Only use specified sources is turned ON.
For now, I am not configuring Capabilities and suggested prompts for this agent. if required, you can enhance this agent by:
- Adding capabilities to control how the agent behaves
- Adding suggested prompts to guide users on how to interact with the agent

- Then click on create, or you can test by giving the prompt. I already tested this, so I clicked the create button.

After creating the agent, you will see a success confirmation pop-up. From this pop-up, you can:
- Click Go to agent to test the agent immediately, or
- Click Share to share the agent with other users

Test the Custom Agent in Microsoft 365 Copilot
Click Go to agent. Then provide the prompt. For this example, I want to search “How to Set up Manual Authentication in Microsoft Copilot Studio”, present or not.

Then you can see the result.

Then, I am searching for “Change Data Type”, you can see the result.

This way, you can create your custom agent in M365 Copilot.
Share Custom Agent in Microsoft 365 Copilot
- Click on All agents.
- Find your custom agent in the list.
- Click the three dots (⋯) next to your agent.
- Select Share.

After clicking Share, a dialog box will appear where you can control who can access the agent.
You will see the following options:
- Anyone in your organization: Select this option if you want all users in your organization to use the agent.
- Specific users in your organization: Select this option if you want to share the agent with selected users only. You can add users by typing their name, group, or email address.
- Only you: Select this option if you want to keep the agent private.
After selecting the appropriate option:
- Click Apply.
- You can also copy the generated agent link and share it directly with your colleagues.

In this, I am sharing this agent with Patti Fernandez.
If she wants to use this agent, she needs to open the M365 Copilot and click the All agent in the schedule. Then she can see the “Shared with you” section. She can see the agent, then install it, and then use it.

In this tutorial, we learned how to create a custom search agent in Microsoft 365 Copilot. We saw how to configure the agent, add clear instructions, and limit the knowledge sources to specific websites like SPGuides and EnjoySharePoint. We also tested the agent to check whether a blog post exists and learned how to share the agent with colleagues in the organization.
Also, you may like some tutorials:
- Create Multi Agent in Copilot Studio
- SharePoint List as Knowledge in Copilot Studio
- Change Copilot Studio Agent Welcome Message
- Add Copilot Studio Knowledge Files Using Power Automate
- Read Excel File & Add Bulk Data to SharePoint List

Hey! I’m Bijay Kumar, founder of SPGuides.com and a Microsoft Business Applications MVP (Power Automate, Power Apps). I launched this site in 2020 because I truly enjoy working with SharePoint, Power Platform, and SharePoint Framework (SPFx), and wanted to share that passion through step-by-step tutorials, guides, and training videos. My mission is to help you learn these technologies so you can utilize SharePoint, enhance productivity, and potentially build business solutions along the way.