Adam BlansettSenior Full-Stack & AI Engineer
Software Modernization
9 min read
Adam Blansett

How to Tell If Your Dev Agency Wrote Bad Code (Before Paying for a Rewrite)

Seven objective repository and operational red flags that reveal whether a dev agency wrote brittle software—and how to verify what is salvageable before signing a rewrite contract.

Codebase AuditAgency RescueTechnical Due DiligenceRefactoring

Few situations burn startup runway faster than paying an outside development agency tens of thousands of dollars—only to end up with an app that stalls on simple changes, breaks whenever users log in, and triggers a pitch for an expensive 'Phase 2 rewrite.'

You do not need to be a senior systems architect to inspect whether your codebase was engineered for production or duct-taped together for weekly demo calls. Use these seven objective checks alongside our Production Readiness Grader before committing another dollar.

7 Objective Red Flags Inside an Agency Codebase#

  • 1. You don't own the GitHub organization or cloud accounts: If code lives on an agency's private server and you only see screen-shared builds, you lack operational control over your own IP.
  • 2. No automated tests or failing CI silenced on merge: Open GitHub Actions (or `.github/workflows/`). If there are zero test suites—or CI skips linting/typechecking with `|| true`—every deployment is unverified guesswork.
  • 3. `// @ts-ignore`, `any` everywhere, or disabled strict mode: Suppressing compiler safety hides mismatched frontend/backend API contracts until customers hit runtime crashes.
  • 4. Secrets or `.env` files committed to Git history: Hardcoded API keys, database passwords, or `NODE_TLS_REJECT_UNAUTHORIZED=0` flags signal dangerous security shortcuts.
  • 5. No database migrations—only manual SQL edits: If schema changes aren't tracked via Prisma, Alembic, Drizzle, or versioned SQL migrations, staging and production will drift out of sync permanently.
  • 6. Fixing one bug breaks two unrelated screens: Tight coupling and duplicated business logic across giant 1,500-line files make regression bugs inevitable.
  • 7. Zero error monitoring or structured logging: When a customer hits a 500 error and the team says 'we can't reproduce it on our laptop,' Sentry/observability was never wired properly.
ten-minute-sanity-check.sh
# 1. Check whether automated tests & typecheck actually run cleanly
npm run typecheck && npm test
# 2. Scan for release-readiness blockers & committed secrets
npx release-readiness-action

Fixing vs. Rewriting: Get Evidence Before Spending#

Even a messy codebase often hides years of real business logic and working UI flows that are far cheaper to rescue than rebuild from scratch. Read Refactor vs. Rewrite and Senior Freelance Engineer vs. Software Dev Agency for a direct breakdown of when targeted rescue beats a new agency SOW.

If your developer disappeared or an agency stalled, start on the App Rescue Triage page or book a fixed-scope $2,500 48-Hour Codebase Audit backed by a 100% actionability guarantee.

Get an Honest Second Opinion in 48 Hours#

Whether you are preparing to transition away from an agency or deciding how to stabilize an MVP before raising capital, visit /start/, explore Technical Consulting & Advisory, or schedule a free 30-minute call for straight answers.

Applied Architecture

Production Case Studies & Capabilities

Explore how these engineering patterns are deployed in production systems and available through client engagements.

Case Study

Release Readiness Action

A published GitHub Marketplace Action (`ncc`-bundled) and `@adamblansett/release-readiness-action` CLI enforcing 8 pre-flight release gates—including 100% local redacted secret scanning, Node/TS entry-point verification, opt-in arg-array script execution, git tag-to-version alignment, and PR annotations—with 74 passing Vitest tests.

Read Case Study
Related Engineering Service

Technical Consulting & Advisory

Making the wrong technology choices, hiring the wrong vendor, or misjudging project scope can cost months of runway and hundreds of thousands of dollars.

Frequently Asked Questions

Can a non-technical founder spot bad engineering without reading every file?
Yes. Operational symptoms—missing automated CI checks, inability to spin up staging cleanly, every small bug fix breaking another screen, and refusal to grant direct GitHub admin access—are reliable indicators of structural technical debt.
Why would an agency push for a ground-up rewrite instead of fixing what exists?
Full rewrites reset expectations and lock in months of predictable retainer billing, whereas an honest audit often proves 70% of the product can be stabilized through targeted refactoring and automated tests.
What does a 48-Hour Codebase Audit check?
It inspects repository security, database queries and migrations, authentication boundaries, CI/CD reliability, error observability, and module coupling—delivering a prioritized risk matrix and concrete remediation patches.
Share this technical guide

Need Help Solving This in Your Application?

I partner with founders, executives, and engineering leaders to design architectures, resolve production bottlenecks, and deliver resilient software.

Related Technical Articles