Development
code review
programming
best practices
debugging

Code Review Assistant

Get comprehensive code reviews with security, performance, and best practice recommendations

AI Prompt

You are a senior software engineer with expertise in code quality, security, and performance optimization. Review the following code and provide comprehensive feedback. <programming_language> {{SPECIFY_LANGUAGE}} </programming_language> <code_context> {{DESCRIBE_WHAT_THIS_CODE_DOES}} </code_context> <code_to_review> {{PASTE_YOUR_CODE_HERE}} </code_to_review> Please provide a detailed code review covering: 1. **Functionality Analysis** - Does the code accomplish its intended purpose? - Edge cases handled/missed - Logical errors or bugs 2. **Code Quality** - Readability and maintainability - Naming conventions - Code organization and structure - DRY principle violations 3. **Performance Considerations** - Time complexity analysis - Space complexity analysis - Optimization opportunities - Database query efficiency (if applicable) 4. **Security Review** - Potential vulnerabilities - Input validation issues - Authentication/authorization concerns - Data exposure risks 5. **Best Practices** - Language-specific conventions - Design pattern opportunities - Testing considerations - Documentation needs 6. **Refactored Version** - Provide an improved version of the code - Explain each significant change Format your review with clear sections, severity levels (Critical/High/Medium/Low), and actionable fixes.

Example AI Output

Code Review Summary

Overall Assessment: Several critical security issues and performance bottlenecks identified. Refactoring strongly recommended before production deployment.

1. Functionality Analysis

Working Correctly:

  • Basic user authentication flow functions as intended
  • Password hashing implemented

Issues Identified:

  • [CRITICAL] No rate limiting on login attempts - enables brute force attacks
  • [HIGH] Missing email verification step in registration
  • [MEDIUM] No password complexity requirements enforced

2. Code Quality

Readability: 6/10

Issues found:

  • Variable names like usr, pwd, res reduce readability
  • Inconsistent indentation (mixing tabs and spaces)
  • No comments explaining business logic
💡 How to Use This Prompt
  1. 1. Copy the prompt above using the “Copy Prompt” button
  2. 2. Paste it into your favorite AI tool (ChatGPT, Claude, Gemini, Cursor, Claude Code, etc.)
  3. 3. Replace the placeholder text in {{BRACKETS}} with your specific information
  4. 4. Customize any parts of the prompt to better fit your needs
  5. 5. Run the prompt and iterate on the output as needed