Suggestions appear as you type. Use the up and down arrows to choose one and Enter to open it.

This page's audience our own tag's counts — open to see them
–Visits
–Page views
–Clicks to vendors
–Time on page
–Reading now
Clicks to vendors, by tool
  • –
Top countries
  • –
Devices
  • –

– · visits, page views and clicks counted by our own tag, which counts more than our checked analytics; every figure rounded down · how we count

Flog review

Free#19 of 21 in Ruby Static Analysis Tools

An open-source Ruby tool for scoring method and class complexity locally.

6.7/10Editor score
Flog6.7 Visit Flog

Reviewed by iTechGuides Editors · Editorial team · Updated Oct 2026

Flog is an open-source command-line and library tool for measuring Ruby code complexity. It is aimed at Ruby developers and teams who want to identify complex methods and classes in local development or CI workflows. Distributed as a Ruby gem under the MIT license, it can process Ruby files and report where complexity is concentrated. Its scope is specific: Flog measures complexity rather than serving as a broader static analysis suite.

Its central metric combines ABC-style assignments, branches and conditionals with a compounding penalty for increasing code depth. Flog calculates scores for methods and classes, then produces a readable pain report with scores and thresholds to help direct attention to the most complex code. Directory processing is supported through automatic path expansion with path_expander. Arguments can also be persisted in an @file_of_args file, and intersecting file or directory paths can be subtracted. Ruby syntax errors and timeouts are handled, which matters when processing source files as part of a development or CI workflow.

Flog is a fit for teams seeking complexity measurements they can run themselves, including solo, small and mid-market teams. The published product details describe it as self-hosted, with no hosted option, and list documentation as its support channel. Its feature set does not include security analysis, type checking or autofix, so teams needing those capabilities should consider a broader analysis tool rather than expecting Flog to cover them. For Ruby developers whose priority is understanding method and class complexity, its metrics-focused approach keeps the task clear; for buyers wanting hosted analysis or a wider set of code-quality functions, it is a narrower choice.

Flog pros and cons

  • Where it wins
    • Scores classes and methods with ABC-style metrics and depth penalties
    • Readable pain reports surface complex code with scores and thresholds
    • Supports directory expansion and reusable argument files
  • Where it doesn't
    • Focuses on complexity rather than security analysis or type checking
    • Does not provide autofix features
    • No hosted option; support is through documentation

Flog fact sheet, pricing and score →

Advertiser disclosure: iTechGuides is reader-supported. Vendors can pay for top positions in our rankings and for a place on other products' pages, and we may earn a commission when you click some links. Bought places stand at the number bought; this page and our disclosure say so. Paying vendors may get a fuller, more detailed review from our editors, and that review can change their score. How we rank.

Last updated · How we research and update