GitHub Copilot app for Beginners: How to teach Copilot about your codebase
Learn how to tailor GitHub Copilot for your project with custom instructions, agent skills, custom agents, and MCP servers.
Intelligence analysis by Qwen 2.5 (3B)

Explore four ways to make GitHub Copilot work better for your project: custom instructions, agent skills, custom agents, and MCP servers.
GitHub Copilot is like a smart helper for your code. It can make changes to your code, but it needs to know the rules of your project. You can tell Copilot about the rules in different ways, like writing instructions in a special file, or using special folders for different tasks. This way, Copilot can follow the rules and make changes correctly.
Analysis
Custom Instructions
Custom instructions define the conventions Copilot should follow across the repository or for particular files. They are defined in a .github/copilot-instructions.md file or in path-specific instruction files inside .github/instructions. Custom instructions can be more specific by using the applyTo field to specify when the guidance is relevant.
Agent Skills
Agent skills package repeatable procedures that Copilot can load when they’re relevant. They are defined in a .github/skills folder, with each skill in its own subfolder. Skills can include instructions, scripts, and other resources. The description in SKILL.md helps Copilot determine when the skill applies.
Custom Agents
Custom agents provide focused expertise and guidance for broader tasks. They are defined in a .github/agents folder and can define the agent’s purpose, instructions, tools, and relevant project context. Custom agents are useful for tasks that require specialized knowledge or expertise.
MCP Servers
MCP servers connect Copilot to external tools, data sources, and services. They can be used to give Copilot access to framework guidance or to open and interact with your application in a browser. Once configured, you can ask Copilot to use the MCP server to perform a task.
Key points
- Use custom instructions to define the conventions Copilot should follow.
- Package repeatable procedures as agent skills for specific tasks.
- Create custom agents for complex tasks that require specialized knowledge.
- Use MCP servers to connect Copilot to external tools and data sources.
By using custom instructions, agent skills, custom agents, and MCP servers, developers can make GitHub Copilot work better for their projects, saving time and reducing the need for repetitive explanations.
If developers don't use these customizations effectively, Copilot might not understand the rules of their project, leading to incorrect changes or errors.