Sourcegraph architecture overview

This is a high level overview of Sourcegraph's architecture so you can understand how our systems fit together. You can click on each component to jump to its respective code repository or subtree.

Note that almost every service has a link back to the frontend, from which is gathers configuration updates. These edges are omitted for clarity.


We maintain multiple Sourcegraph clients:

These clients generally communicate with a Sourcegraph instance (either or a private customer instance) through our GraphQL API. There are also a small number of REST endpoints for specific use-cases.


Our backend is composed of multiple services:



Here are some references to help you understand how multiple systems fit together: