SOLFIND
Web Lens
Portal home

Setting up Copilot for learning to code - GitHub Docs

https://docs.github.com/en/get-started/learning-to-code/setting-up-copilot-for-learning-to-code • 196 KB fetched
Open original page


Setting up Copilot for learning to code - GitHub Docs Skip to main content GitHub Docs Version: Free, Pro, & Team Search or ask Copilot Search or ask Copilot Select language: current language is English Search or ask Copilot Search or ask Copilot Open menu Collapse sidebar Expand sidebar Scroll breadcrumbs left * Home * Get started * Learn to code * Set up Copilot for learning Scroll breadcrumbs right Get started * * * Start your journey * What is GitHub? * Learning resources * Create your repository * Plan your work * Connect locally * Write and store code * Review changes * Deploy automatically * Onboarding * Getting started with your GitHub account * Getting started with GitHub Team * Getting started with the GitHub Enterprise Cloud trial * Getting started with GitHub Enterprise Cloud * Using GitHub * Hello World * GitHub flow * Connecting to GitHub * Communicating on GitHub * Feature preview * Supported browsers * GitHub Mobile * Allow network access * Connectivity problems * Learning about GitHub * GitHub's plans * GitHub language support * Types of GitHub accounts * Access permissions * GitHub Advanced Security * Changes to GitHub plans * GitHub glossary * Learn to code * Set up Copilot for learning * Get started with Git * Finding example code * Reuse people's code * Local development * Debug with Copilot * Getting feedback on your code * Storing secrets safely * Secure your code * Secure your dependencies * Accessibility * Manage theme settings * Keyboard shortcuts * GitHub Command Palette * Writing on GitHub * Start writing on GitHub * Quickstart * About writing & formatting * Basic formatting syntax * Work with advanced formatting * Organized data with tables * Collapsed sections * Create code blocks * Create diagrams * Mathematical expressions * Auto linked references * Attaching files * About tasklists * Permanent links to code * Using keywords in issues and pull requests * Work with saved replies * About saved replies * Creating a saved reply * Editing a saved reply * Deleting a saved reply * Using saved replies * Share content with gists * Creating gists * Forking and cloning gists * Saving gists with stars * Moderating gist comments * Explore projects * Discover projects * Contribute to a project * Finding open source projects * Contribute to open source * Use Copilot to explore projects * Save repositories with stars * Following people * Following organizations * Git basics * Set up Git * Set your username * Caching credentials * Repeated credential prompts * macOS Keychain credentials * Git workflows * About remote repositories * Manage remote repositories * Associate text editors * Handle line endings * Ignoring files * Git cheatsheet * Using Git * About Git * Push commits to a remote * Get changes from a remote * Non-fast-forward error * Splitting a subfolder * About Git subtree merges * About Git rebase * Git rebase * Resolve conflicts after rebase * Special characters in names * Maximum push limit * Archive account and public repos * Request account archive * GitHub Archive program * Using GitHub Docs * Docs versions * Hover cards * GitHub Docs API * GitHub Certifications * About GitHub Certifications * Registering for an exam Setting up Copilot for learning to code Configure Copilot to help you learn coding concepts and actively build your programming skills. Copy as Markdown Learn to code with GitHub Copilot Article 1 of 10 Next : Getting started with Git In this article * Can Copilot help me learn to code? * Prerequisites * Step 1: Disable Copilot inline suggestions * Step 2: Add learning instructions * Step 3: Use Copilot Chat to learn Can Copilot help me learn to code? Yes! Copilot can adapt to meet your changing needs throughout your coding journey. When you're an experienced developer, you'll use Copilot as a coding assistant. While you're learning to code, it's more beneficial as a supportive companion . In this guide, you’ll learn how to set up Copilot to act as a tutor that will help you build a deep understanding of programming concepts, rather than relying on it to write your code for you. To optimize your learning, follow these steps for each repository you work on! Prerequisites This guide assumes that you'll use Copilot in VS Code. To get set up, see Set up Copilot in VS Code in the Visual Studio Code documentation. Step 1: Disable Copilot inline suggestions First, let's disable inline suggestions. This will give you the opportunity to deepen your understanding of programming concepts by writing more code yourself. * In VS Code, open your project. * Create a folder in the root directory called .vscode . * Inside .vscode , create a file called settings.json . * Add the following text to the file: JSON { "github.copilot.enable": { "*": false } } { "github.copilot.enable" : { "*" : false } } * Save the file. Copilot inline suggestions are now disabled for this project in VS Code. Step 2: Add learning instructions Now, let's provide Copilot Chat with instructions to act like a tutor that supports your learning. * Create a folder in the root directory called .github . * Inside .github , create a file called copilot-instructions.md . * Add the following text, or customize it for your personal learning goals: Markdown I am learning to code. You are to act as a tutor; assume I am a beginner coder. Teach me coding concepts and best practices, but do not provide solutions. Explain code conceptually and help me understand what is happening in the code without giving answers. Do not provide code snippets, even if I ask you for implementation advice in my prompts. Teach me all the basic coding concepts in your answers. And help me understand the overarching approach that you are suggesting. Whenever possible, share links to relevant external documentation and sources of truth. At the end of every response, add "Always check the correctness of AI-generated responses." I am learning to code. You are to act as a tutor; assume I am a beginner coder. Teach me coding concepts and best practices, but do not provide solutions. Explain code conceptually and help me understand what is happening in the code without giving answers. Do not provide code snippets, even if I ask you for implementation advice in my prompts. Teach me all the basic coding concepts in your answers. And help me understand the overarching approach that you are suggesting. Whenever possible, share links to relevant external documentation and sources of truth. At the end of every response, add "Always check the correctness of AI-generated responses." * Save the file. Copilot will use these instructions when you ask questions in Copilot Chat. Step 3: Use Copilot Chat to learn You're ready to start building real coding skills with Copilot's help! Throughout your work on the project, engage in a long-running conversation with Copilot Chat . Treat it as your personal tutor , asking questions as they arise and using it to navigate challenges or clarify concepts. Open Copilot Chat in VS Code Copilot Chat is especially helpful for debugging your code. For step-by-step guidance, see Learning to debug with GitHub Copilot . Up next Getting started with Git Step 1 of 10 in Learn to code with GitHub Copilot Help and support Did you find what you needed? Yes No Privacy policy Help us make these docs great! All GitHub docs are open source. See something that's wrong or unclear? Submit a pull request. Make a contribution Learn how to contribute Still need help? Ask the GitHub community Contact support Legal * © 2026 GitHub, Inc. * Terms * Privacy * Status * Pricing * Expert services * Blog

Links found on this page

  1. Skip to main content [direct]
  2. GitHub Docs [direct]
  3. Get started [direct]
  4. Learn to code [direct]
  5. What is GitHub? [direct]
  6. Learning resources [direct]
  7. Create your repository [direct]
  8. Plan your work [direct]
  9. Connect locally [direct]
  10. Write and store code [direct]
  11. Review changes [direct]
  12. Deploy automatically [direct]
  13. Getting started with your GitHub account [direct]
  14. Getting started with GitHub Team [direct]
  15. Getting started with the GitHub Enterprise Cloud trial [direct]
  16. Getting started with GitHub Enterprise Cloud [direct]
  17. Hello World [direct]
  18. GitHub flow [direct]
  19. Connecting to GitHub [direct]
  20. Communicating on GitHub [direct]
  21. Feature preview [direct]
  22. Supported browsers [direct]
  23. GitHub Mobile [direct]
  24. Allow network access [direct]
  25. Connectivity problems [direct]
  26. GitHub's plans [direct]
  27. GitHub language support [direct]
  28. Types of GitHub accounts [direct]
  29. Access permissions [direct]
  30. GitHub Advanced Security [direct]
  31. Changes to GitHub plans [direct]
  32. GitHub glossary [direct]
  33. Get started with Git [direct]
  34. Finding example code [direct]
  35. Reuse people's code [direct]
  36. Local development [direct]
  37. Debug with Copilot [direct]
  38. Getting feedback on your code [direct]
  39. Storing secrets safely [direct]
  40. Secure your code [direct]
  41. Secure your dependencies [direct]
  42. Manage theme settings [direct]
  43. Keyboard shortcuts [direct]
  44. GitHub Command Palette [direct]
  45. Quickstart [direct]
  46. About writing & formatting [direct]
  47. Basic formatting syntax [direct]
  48. Organized data with tables [direct]
  49. Collapsed sections [direct]
  50. Create code blocks [direct]
  51. Create diagrams [direct]
  52. Mathematical expressions [direct]
  53. Auto linked references [direct]
  54. Attaching files [direct]
  55. About tasklists [direct]
  56. Permanent links to code [direct]
  57. Using keywords in issues and pull requests [direct]
  58. About saved replies [direct]
  59. Creating a saved reply [direct]
  60. Editing a saved reply [direct]
  61. Deleting a saved reply [direct]
  62. Using saved replies [direct]
  63. Creating gists [direct]
  64. Forking and cloning gists [direct]
  65. Saving gists with stars [direct]
  66. Moderating gist comments [direct]
  67. Discover projects [direct]
  68. Contribute to a project [direct]
  69. Finding open source projects [direct]
  70. Contribute to open source [direct]
  71. Use Copilot to explore projects [direct]
  72. Save repositories with stars [direct]
  73. Following people [direct]
  74. Following organizations [direct]
  75. Set up Git [direct]
  76. Set your username [direct]
  77. Caching credentials [direct]
  78. Repeated credential prompts [direct]
  79. macOS Keychain credentials [direct]
  80. Git workflows [direct]