Skip to content
This documentation applies to Codacy Self-hosted

For the latest updates and improvements, see the latest Cloud documentation instead.

How does Codacy measure complexity in my repository?

Codacy uses cyclomatic complexity to identify complex files in your repository. 

Cyclomatic Complexity is a software metric used to indicate the complexity of a program. It is a quantitative measure of the number of linearly independent paths through a program's source code. 

A complex file is a file with a complexity value bigger than the threshold defined on the repository quality settings

Code complexity is calculated based on the maximum number of complex methods in a file.

In your Repository dashboard, you can see how complexity is evolving for your repository. 

Share your feedback 📢

Did this page help you?

Thanks for the feedback! Is there anything else you'd like to tell us about this page?

We're sorry to hear that. Please let us know what we can improve:

Alternatively, you can create a more detailed issue on our GitHub repository.

Thanks for helping improve the Codacy documentation.

If you have a question or need help please contact support@codacy.com.

Last modified July 22, 2020