Skip to main content
GitHub Docs
Version:
Free, Pro, & Team
Search GitHub Docs
Search
Select language: current language is English
Open Search Bar
Close Search Bar
Open Menu
Open Sidebar
GitHub Copilot
/
Copilot Chat Cookbook
/
Refactoring code
/
Performance optimization
Home
GitHub Copilot
Quickstart
About GitHub Copilot
What is GitHub Copilot?
Copilot features
Plans for Copilot
Set up
Set up for organization
Set up for self
Use GitHub Copilot
Best practices
Get code suggestions
Copilot Chat
Chat in IDE
Chat in GitHub
Chat in Mobile
Getting started with chat
Semantic indexing
Prompt engineering
Copilot Chat cheat sheet
Copilot in Windows Terminal
Code review
Using code review
Configuring coding guidelines
Automatic code review
Use Copilot in the CLI
Use Copilot Extensions
AI models
Change the chat model
Change the completion model
Choose the right AI model
Examples for AI model comparison
Use Claude Sonnet
Use Gemini
Use OpenAI GPT-4.1
Use OpenAI o3
Use OpenAI o4-mini
Find matching code
Copilot for pull requests
Working on a PR
Create a PR summary
Guides
Refactor code
Migrate a project
Write tests
Modernize legacy code
Copilot Chat Cookbook
All prompts
Debugging errors
Debug invalid JSON
Handle API rate limits
Functionality analysis and feature suggestions
Explore feature implementations
Incorporate feedback
Refactoring code
Improve code readability
Lint errors
Performance optimization
Design patterns
Data access layers
Decoupling business logic
Cross-cutting concerns
Simplify inheritance hierarchies
Fixing database deadlocks
Translating code
Documenting code
Document legacy code
Explain legacy code
Explain complex logic
Sync documentation
Write discussions or blog posts
Testing code
Generate unit tests