> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fallow.tools/llms.txt
> Use this file to discover all available pages before exploring further.

# Migrating from knip

> Migrate from knip to fallow in minutes. One command converts your knip config. Fallow also covers duplication, complexity, and architecture boundaries that knip does not.

Fallow provides a one-command migration path from knip. Your existing configuration is automatically translated. Beyond what knip covers, fallow also detects code duplication, complexity hotspots, maintainability scores, and architecture boundary violations.

## Migration workflow

<Steps>
  <Step title="Preview the migration">
    Run `fallow migrate --dry-run` to see the generated config without writing anything:

    ```bash theme={null}
    fallow migrate --dry-run
    ```

    Fallow searches for: `knip.json`, `knip.jsonc`, `.knip.json`, `.knip.jsonc`, `knip.ts`, `knip.config.ts`, and the `knip` field in `package.json`. TypeScript config files (`knip.ts`, `knip.config.ts`) are detected but cannot be parsed. Convert to `knip.json` first.

    ```bash title="$ fallow migrate --dry-run" theme={null}
    Detected knip config: knip.json

    Migrating settings:
      entry          → entry: ["src/index.ts", "src/cli.ts"]
      ignore         → ignorePatterns: ["**/*.generated.ts"]
      ignoreDeps     → ignoreDependencies: ["@types/node"]

    ⚠ Cannot migrate:
      ignoreBinaries → not applicable in fallow

    Would write: .fallowrc.json
    Run without --dry-run to write the config.
    ```
  </Step>

  <Step title="Generate the config">
    Once you're happy with the preview, run the migration:

    ```bash theme={null}
    fallow migrate            # Write .fallowrc.json
    fallow migrate --toml     # Or output as fallow.toml
    ```
  </Step>

  <Step title="Review the config">
    Open the generated config and verify the translated entry points, ignore patterns, and plugin mappings. Warnings are shown for any fields that couldn't be migrated automatically.
  </Step>

  <Step title="Run your first analysis">
    Run dead code analysis and compare results against knip. Then explore the other analyses that knip does not cover:

    ```bash theme={null}
    fallow dead-code    # Unused code + circular deps + boundaries
    fallow dupes        # Code duplication
    fallow health       # Complexity hotspots + maintainability scores
    fallow              # All of the above in one pass
    ```
  </Step>
</Steps>

## What gets migrated

| knip                      | fallow                                                                                   |
| :------------------------ | :--------------------------------------------------------------------------------------- |
| `entry`                   | `entry`                                                                                  |
| `project`                 | -- (fallow auto-discovers project files)                                                 |
| `ignore`                  | `ignorePatterns`                                                                         |
| `ignoreDependencies`      | `ignoreDependencies`                                                                     |
| `ignoreExportsUsedInFile` | `ignoreExportsUsedInFile` (boolean and `{ type, interface }` object form both supported) |
| `ignoreBinaries`          | -- (not applicable)                                                                      |
| Plugin configs            | Closest fallow plugin equivalent                                                         |

## Comparison

<Tabs>
  <Tab title="Speed">
    Fallow is a Rust-native standalone binary. No Node.js runtime, no JIT warmup, no garbage collection pauses.

    | Metric             | fallow                   | knip                            |
    | :----------------- | :----------------------- | :------------------------------ |
    | Speed vs knip v5   | **3--36x faster**        | Baseline                        |
    | Speed vs knip v6   | **2--14x faster**        | Baseline                        |
    | Memory usage       | **3--11x less**          | Baseline                        |
    | Runtime dependency | None (standalone binary) | Node.js                         |
    | CI setup           | Download binary          | Install Node + npm dependencies |
  </Tab>

  <Tab title="Features">
    | Feature               | fallow                    | knip                   |
    | :-------------------- | :------------------------ | :--------------------- |
    | Duplication detection | Built-in (`fallow dupes`) | Not included           |
    | SARIF output          | Yes                       | No                     |
    | Baseline comparison   | Yes (`--baseline`)        | No                     |
    | Git-aware analysis    | `--changed-since`         | No                     |
    | Production mode       | `--production`            | No                     |
    | Auto-fix              | Exports + dependencies    | Exports + dependencies |
    | Config format         | JSONC, JSON, TOML         | JSON, TS               |
  </Tab>

  <Tab title="Coverage">
    | Metric                | fallow                      | knip |
    | :-------------------- | :-------------------------- | :--- |
    | Framework plugins     | 94 (39 with config parsing) | 141  |
    | Dead code issue types | 15                          | 10   |
    | Custom plugins        | Yes                         | Yes  |
  </Tab>
</Tabs>

## Key differences

### No runtime dependency

Fallow is a standalone binary. No Node.js runtime, no dependency conflicts, faster CI setup.

## See also

<CardGroup cols={2}>
  <Card title="Custom plugins" icon="plug" href="/frameworks/custom-plugins">
    Build plugins for frameworks fallow doesn't cover yet.
  </Card>

  <Card title="fallow migrate" icon="terminal" href="/cli/migrate">
    Full CLI reference for the migrate command.
  </Card>
</CardGroup>
