How to Use Cursor's Chat Panel
Master Cursor's AI chat panel. Ask questions, debug code, and get context-aware answers about your entire codebase.
Step-by-step
How to Use Cursor's Chat Panel
Open the chat panel
Press Cmd+L (Mac) or Ctrl+L (Windows/Linux) to open the chat panel on the right side. This is your main interface for asking AI questions about your code.
Ask questions about your code
Type natural language questions like 'how does the auth middleware work?' or 'what does this function do?'. Cursor reads your codebase to provide accurate, contextual answers.
Reference specific files with @
Use @filename to add specific files to the conversation context. For example: '@auth.ts explain the JWT validation logic'. You can also use @folder to include entire directories.
Apply suggested code changes
When the chat suggests code changes, click the 'Apply' button to insert them directly into your editor with a visual diff. Review the diff before accepting.
Tips
Pro tips
- *
Use @codebase to search your entire project for relevant context
- *
Start a new chat (Cmd+Shift+L) to reset context when switching topics
- *
You can select code in the editor before opening chat — it's automatically included as context
Related guides