Answer: To add repository-wide custom instructions, create a .github/copilot-instructions.md file in the root of your repository. For path-specific instructions, create one or more .github/instructions/**/*.instructions.md files and use the glob pattern in the front matter to specify which file types they apply to. Status: Confirmed Entry: tool/github-copilot/memory-and-context/repository-custom-instructions-2 Revision: 3 Digest: sha256:37a757ff73310acf (changes whenever the content changes) Timeline: Created: 2026-11-13T03:33:03Z Last changed: 2026-11-19T13:08:38Z (front matter glob key: — → applyTo) Last verified: 2026-11-20T13:14:56Z Next check: 2026-11-21T13:14:56Z Check interval: Daily Expected change: No fixed schedule Data: Field | Value | Source | As of repository-wide instructions file | .github/copilot-instructions.md | [1] | 2026-11-20 path-specific instructions files | .github/instructions/**/*.instructions.md | [1] | 2026-11-20 supported instructions file types | /.github/copilot-instructions.md | [1] | 2026-11-20 front matter glob key | applyTo | [1] | 2026-11-20 Sources: [1] GitHub. "Best practices for using GitHub Copilot to work on tasks - GitHub Docs". https://docs.github.com/en/copilot/tutorials/cloud-agent/get-the-best-results Role: primary. Accessed: 2026-11-20T13:14:56Z Quote: "create a .github/copilot-instructions.md file in the root of your repository" (Supports: repository-wide instructions file) Quote: "create one or more .github/instructions/**/*.instructions.md files in your repository" (Supports: path-specific instructions files) Quote: "Copilot in the cloud supports a number of different types of custom instructions files: /.github/copilot-instructions.md" (Supports: supported instructions file types) Quote: "Using the glob pattern in the front matter of the instructions file, you can specify the file types to which they should apply. For example, to create instructions for Playwright tests you could create an instructions file called .github/instructions/playwright-tests.instructions.md with the following content: --- applyTo" (Supports: front matter glob key) Snapshot SHA-256: cffdb953bf46f893da44ed9ae692a87b7f938363476aba00b4d092c3d3c83418 (captured 2026-11-18T13:11:24Z) Verification: Method: Automated extraction from [1] with deepseek-flash (JSON output, thinking disabled). Every value was checked by code to appear verbatim in a quoted passage of [1]. On this check the text of [1] was unchanged since 2026-11-18T13:11:23Z, so the values verified then were kept. Cross-check: not-available at 2026-11-20T13:14:56Z. No independent second source is configured for this entry Last successful check: 2026-11-20T13:14:56Z Last attempt: 2026-11-20T13:14:56Z Notes and limitations: Extracted automatically from a single official source (section "Adding custom instructions to your repository"). Related: https://latestn.com/tool/github-copilot/memory-and-context/repository-indexing How do I index repositories for GitHub Copilot? https://latestn.com/tool/github-copilot/memory-and-context/semantic-search-copilot-chat How does semantic code search work in GitHub Copilot Chat? https://latestn.com/tool/github-copilot/memory-and-context/set-global-and-repo-instructions How do I set global and repository-specific custom instructions in the GitHub Copilot app? https://latestn.com/tool/github-copilot/memory-and-context/personal-custom-instructions How do I set up personal custom instructions in GitHub Copilot? https://latestn.com/tool/github-copilot/memory-and-context/provide-relevant-context How do I give GitHub Copilot relevant context in my prompts? https://latestn.com/tool/github-copilot/memory-and-context/repository-custom-instructions How do I set up repository custom instructions for GitHub Copilot? https://latestn.com/tool/ All entries in AI tools Change log: Time | Event | Change | Source 2026-11-19T13:08:38Z | changed | front matter glob key: — → applyTo | [1] 2026-11-19T13:08:38Z | changed | glob pattern front matter: applyTo → — | [1] 2026-11-17T13:34:50Z | changed | glob pattern front matter: — → applyTo | [1] 2026-11-17T13:34:50Z | changed | supported instructions file types: — → /.github/copilot-instructions.md | [1] 2026-11-17T13:34:50Z | changed | path-specific instructions files: — → .github/instructions/**/*.instructions.md | [1] 2026-11-17T13:34:50Z | changed | repository-wide instructions file: — → .github/copilot-instructions.md | [1] 2026-11-17T13:34:50Z | changed | Front matter glob pattern: applyTo → — | [1] 2026-11-17T13:34:50Z | changed | Supported instruction file types: /.github/copilot-instructions.md → — | [1] 2026-11-17T13:34:50Z | changed | Path-specific instructions files: .github/instructions/**/*.instructions.md → — | [1] 2026-11-17T13:34:50Z | changed | Repository-wide instructions file: .github/copilot-instructions.md → — | [1] 2026-11-13T03:33:03Z | added | Entry created | — Changes for this entry as a feed: https://latestn.com/tool/github-copilot/memory-and-context/repository-custom-instructions-2/latest Challenge this entry: Open challenges: None How: If a value here is wrong or out of date, send what is wrong and a link to evidence. Challenges are queued and checked against the evidence; they do not change the entry by themselves. If the entry changes as a result, the change log says so. Form: https://latestn.com/dispute/tool/github-copilot/memory-and-context/repository-custom-instructions-2 POST: https://latestn.com/dispute/tool/github-copilot/memory-and-context/repository-custom-instructions-2 with claim, evidence_url, and optionally field and contact (form-encoded or JSON) GET: https://latestn.com/dispute/tool/github-copilot/memory-and-context/repository-custom-instructions-2?claim={what is wrong}&evidence_url={link} How to cite: LatestN. (2026). How do I add custom instructions to a repository for GitHub Copilot? Revision 3, last verified 2026-11-20T13:14:56Z. https://latestn.com/tool/github-copilot/memory-and-context/repository-custom-instructions-2 (accessed 2026-11-21T10:00:43Z). @misc{LatestN_tool_github_copilot_memory_and_context_repository_custom_instructions_2_r3, title = {How do I add custom instructions to a repository for GitHub Copilot?}, author = {{LatestN}}, year = {2026}, howpublished = {\url{https://latestn.com/tool/github-copilot/memory-and-context/repository-custom-instructions-2}}, note = {Revision 3; digest sha256:37a757ff73310acf; last verified 2026-11-20T13:14:56Z; accessed 2026-11-21T10:00:43Z} } Reuse: License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/) Attribution: Copying and adapting are allowed, including commercially, if you credit LatestN and link to the entry you used. Each entry ends with a ready-made citation. URL: https://latestn.com/tool/github-copilot/memory-and-context/repository-custom-instructions-2