Free and open-source cross-platform source explorer

NEWS: We decided to discontinue Sourcetrail and will archive the repository. Read more

Supported Languages:

C, C++, Java, Python, <custom>;
more info

Used and tested on code bases with up to 10 million lines of code. See pre-indexed projects.

Connectable Editors:

Atom, Clion, Eclipse, Emacs, IntelliJ IDEA, Neovim, PyCharm, QtCreator, Sublime Text, Vim, Visual Studio, Visual Studio Code;
more info

Software developers spend most of their time figuring out existing source code, but common code editing tools offer little help for this task. Debuggers only allow detailed inspection of one narrow code path. 'Find all references' helps you in navigating between files, but doesn't provide the context to see the big picture of all relevant dependencies. Sourcetrail provides both overview and details by combining an interactive dependency graph, a concise code view and efficient code search, all built into an easy-to-use cross-platform developer tool. It supports you in exploring legacy code, understanding the implementation and refactoring the software architecture, making it a fun experience for the whole family!

Sourcetrail runs locally.
Your code is private. No cloud necessary.

How It Works

1 Index your Source Code

Sourcetrail's in-depth static analysis finds all definitions and references within your source files. To start the static code analyzer, you can either import an existing build configuration or choose manual project setup.

Index your Source Code

2 Find any Symbol

Use Sourcetrail's search field to quickly find any symbol within the whole codebase. The fuzzy code search engine gives you the best matches with just a few keystrokes.

Find any Symbol

3 Explore Dependencies Visually

The graph visualization provides a quick overview of any class, method, field, etc., of interest and all its relations. The dependency graph is fully interactive. Use it to move through the codebase by focusing on related nodes and edges.

Navigate Visually

4 Browse your Source Code

Finally the code view holds all implementation details of the element in focus within a well-arranged list of code snippets. Further inspect scopes and highlight local variables, or focus on any other encountered reference or element.

Explore your Code

5 Connect your Source Editor

Synchronize Sourcetrail with your favorite source code editor via plugin. This allows for easy switching between writing and exploring. Have a look at our list of supported editors.

Connect your Source Editor

Why Sourcetrail?

The reality of software development.

As software engineers, we know that we have the skills and capacity to actualize all of our ideas. But sometimes, it’s more difficult than we expect. Professional software development is often a team effort. Working in teams allows us to solve harder problems, but it comes at a cost. When a codebase grows, it becomes increasingly complex to track every addition. Consequently, more and more effort is spent investigating the current implementation while less is spent on writing new features. New Developers will often have to spend days or even weeks browsing legacy code to familiarize themselves with the implementation before actually becoming productive.

Programming languages are not the problem.

Programming languages are constantly evolving. They reduce the overhead a software developer needs to keep in mind by abstracting away more and more limitations of the machine. But regardless of the language, if a project reaches a certain size, it's hard to keep a consistent mental model of the source code's structure. The problem here is not the poor abstraction of the language, but the high information density of code. Every line in the source code has a purpose and as software developers, we spend most of your time searching for those small pieces that are currently relevant. Why can't we take a step back and see how the components connect with each other, without constantly looking at every detail of code?

We already have enough code editors.

When it comes to writing code, we have a multitude of options to suit whatever workflow we desire. What is harder to address is how efficiently we can understand an existing implementation. While there are many great code editors out there, they’re designed for writing code and are not made for navigating the implementation at hand. Sure, every developer has their own strategy of finding information within source code, from searching documentation to looking at tests, or asking the original authors when available. But when you’ve exhausted all these options, you are inevitably left with digging through code. And let’s face it—digging through is something that most programmers would rather avoid.

The computer knows it all!

Understanding the fundamentals of your software architecture shouldn’t be that hard. Seeing which objects are involved in a feature and the paths that it takes through the source files should be a no-brainer. The funny thing about all this? Your computer knows it all. By using a compiler or interpreter, your computer already knows how the language works. It knows what paradigms exist and because it's turning your source code into executable instructions; it knows every single piece of information within the entire codebase, including: where functions are called, how types get instantiated, where variables get changed. Accessing this information was cumbersome for us developers so far, but is easily possible with Sourcetrail.

Meet Sourcetrail, the interactive source code browser!

We want you to meet Sourcetrail, the lightweight code visualizer specifically crafted for fast and comprehensive navigation within your source code. Sourcetrail utilizes software visualization to dynamically generate interactive code maps of any selected type, function, variable, etc. and shows all their dependencies to the rest of the codebase. But a fancy code visualization or class diagram alone can’t make you really understand any source code. That’s why Sourcetrail also shows the relevant code snippets alongside the visualization. Finally, the package is completed by a powerful code search algorithm that gets you started as fast as possible. Sourcetrail shortens the time used up by reading source code and leaves you with more time to spend on things that you actually enjoy doing as a software developer. Start using Sourcetrail today!

User Testimonials

Sourcetrail helps me getting a grip on a large unfamiliar codebase. It gives me a unique perspective on code between the big picture and the gory details which contemporary IDEs don't provide.

Sourcetrail is the tool I wish I had for the last twenty years. Making sense of a large source base of C and C++ has never been easier.

Day after day, Sourcetrail is proving an invaluable tool for both getting acquainted with others' codebases and getting back to personal side projects I can't work on continuously.

Forget architectural and design documents that are anyway almost always out-of-date, whenever I need to understand a new codebase, Sourcetrail is my first step to get a conceptual, higher-level overview of how things are connected.

I was struggling to understand a huge legacy system my team was tasked with supporting. Sourcetrail (then Coati) helped us untangle the spaghetti code and its dependencies, letting us see what would be affected when we touched each function.

Nelson Ferrari, USA

It's very rare to encounter software projects that are considerate to a fresh set of eyes when trying to be productive using them. Sadly, this is true of a large number of 3rd party open source projects or even in-house legacy software. As a software professional, I saw great value in what Sourcetrail hoped to achieve.

Having experimented with Sourcetrail over the past few months while dissecting a number of complex projects, I have been impressed to see the barriers to entry being removed. Individual layers of software being revealed before my eyes with class diagrams, caller graphs, callee graphs & more all presented accurately and interactively.

My understanding of the software dependencies I'm using has increased dramatically and as a result so has my productivity. Great work Sourcetrail!

Andrew Foster, UK
Explore Classes Visually Explore Classes Visually
Find Symbols with Fuzzy Search Find Symbols with Fuzzy Search
Connect your Editor via Plugin Connect your Editor via Plugin
Follow Calls in Graph or Code Follow Calls in Graph or Code
View Call and Inheritance Graphs View Call and Inheritance Graphs
Use History and Bookmarks Use History and Bookmarks

Get Started!

Sourcetrail is free and open-source software. Download now, contribute or become a patron.

Keep updated about new features and releases by joining our mailing list. * This service is powered by MailChimp. By subscribing to our mailing list, you acknowledge that your e-mail address will be transferred to MailChimp for processing in accordance with their Privacy Policy and Terms

Sign up to our mailing list:

or follow us on social media