Cody Logo

Meet Cody,

The AI that knows your entire codebase

Cody answers code questions and writes code for you by reading your entire codebase and the code graph.

Sign up to get free access 👇

By registering, you agree to our Terms of Service and Private Policy

Watch Cody write & fix code

4 min

Watch now

We’re working to bring you Cody where you need it most

Sourcegraph Web UI

VS Code extension

Sourcegraph app
Coming soon!

IntelliJ extension
Coming soon!

Codebase-aware intelligence

Answer questions about both general programming topics and your specific codebase from right inside your editor. Cody knows about your local code and can learn from the code graph and documentation inside your organization to do just that.

See the Cody docs

Code navigation

Cody can help you find functions & components from around your codebase. Ask Cody where a certain component is defined—such as a webapp navbar, or an API schema—and Cody will point you to the file where it lives.

Code explanation

Cody can explain what code is doing—at a high level or in detail. Highlight any code block or an entire file and Cody will explain what’s happening in conversational language.

Code smells

Cody can act as a pair programmer and analyze code blocks for code smells, potential bugs, and unhandled errors. Cody will point out issues in selected code such as magic numbers, unhandled edge cases, or unclear variables names, with suggestions to fix those issues.

Summarize recent code changes

Cody is able to reference recent diffs to tell you about recent changes to your code. Cody can generate summaries of changes to an entire repository over the last day or week or summarize the changes specific to a selected file.

Translate language

Cody translates selected code between programming languages. You can feed code snippets to Cody—for example, a certain function—and Cody can translate that code, providing you with a code snippet of another language with the same functionality.

Debugging assistance

Cody can help you debug and improve your code. Pass in a code snippet to the Cody chat and request a specific fix—such as handling for a new edge case—and Cody will provide a rewritten code suggestion.

Reference tracking

Cody knows where all your functions are referenced throughout your code and can find and return function references at your request.

AI-generated code

Cody uses knowledge of your codebase to write and fix code. Generate everything from boilerplate code to API resolvers that rely on the context and style of your codebase. You can even ask Cody to fix code blocks for errors, readability, or unhandled edge cases, and Cody will make changes directly in your working file.

Documentation generation

Cody can read and understand your code, which means it can also write documentation for you. Highlight a snippet of code—for example, a function or class—and Cody can generate a docstring for it.

Code generation

Cody generates new code on request via the chat. You can ask Cody to write boilerplate code, API calls, or even specific code based on your instruction and requirements.

Code fixup

Cody edits and improves code directly using inline instructions. Simply type what you want Cody to do above or below a block of Cody and hit the Fixup hotkey; Cody will directly edit that code within your editor, saving you the need to copy and paste code from the chat.

Unit tests

Cody writes unit tests for you, saving you time and letting you stay focused on building software. Highlight a code block and trigger the "Generate a unit test" recipe; Cody will write a unit test ready to be pasted into your code.

Code completions

Start writing code or write a comment and Cody will suggest the next few lines for you. Choose to accept it, or open the command palette and click "Cody: View Suggestions" to see various code snippets Cody suggests using.

Get Cody where you work

Cody for work provides context-aware answers based on your own private codebase. Contact us through the form to learn more.

See what devs are building with Cody

Cody for personal use

Cody is free for personal use in Sourcegraph.com and in the VS Code extension. Create a free Sourcegraph.com account to get started.

By registering, you agree to our Terms of Service and Private Policy

Cody for work

Cody for work provides context-aware answers based on your own private codebase. Contact us with the form below to learn more.

Get Cody for work