{
 "kind": "tool",
 "slug": "diff",
 "path": "tools/diff/",
 "name": "diff",
 "maker": null,
 "density": "basic",
 "crumbs": [
  [
   "Tools",
   "tools/"
  ],
  [
   "Utilities",
   "tools/utilities/"
  ]
 ],
 "lead": "JavaScript text diff implementation for comparing and generating unified diffs.",
 "chips": [
  {
   "label": "Utilities",
   "path": "tools/utilities/"
  },
  {
   "label": "NPM"
  }
 ],
 "primary": {
  "label": "Copy install command",
  "copy": "npm install diff"
 },
 "links": [
  {
   "label": "GitHub",
   "href": "https://github.com/kpdecker/jsdiff"
  }
 ],
 "track": "New versions, deprecation and license changes on your dashboard",
 "verdicts": [
  {
   "key": "license",
   "label": "License",
   "value": "BSD-3-Clause",
   "status": "yes",
   "sub": "Use it in paid apps",
   "quote": null,
   "note": "License from npm.",
   "src": "https://github.com/kpdecker/jsdiff"
  },
  {
   "key": "maint",
   "label": "Maintained",
   "value": "Maintained",
   "status": "yes",
   "sub": "Last change Nov 23, 2026",
   "note": "",
   "src": "https://github.com/kpdecker/jsdiff"
  },
  {
   "key": "pop",
   "label": "Used by agents' projects",
   "value": "54 projects",
   "status": "info",
   "sub": "#25 of 408 in its category",
   "note": "Dependency in 54 public GitHub projects set up for AI coding agents that we scanned (0.9%).",
   "src": null
  },
  {
   "key": "agent",
   "label": "Agent access",
   "value": "Install only",
   "status": "info",
   "sub": null,
   "note": "Agent skills for this library in the skills catalog; community skills are written by others, read them before you install.",
   "src": null
  }
 ],
 "vfoot": "From the package registry and GitHub, checked daily.",
 "blocks": [
  {
   "id": "overview",
   "nav": "Overview",
   "h2": "What diff does",
   "parts": [
    {
     "t": "prose",
     "text": "JavaScript text diff implementation for comparing and generating unified diffs."
    }
   ]
  },
  {
   "id": "popularity",
   "nav": "Popularity",
   "h2": "diff popularity",
   "parts": [
    {
     "t": "stats",
     "items": [
      {
       "n": "73",
       "of": "/ 100",
       "l": "Gid Score, #267 overall"
      },
      {
       "n": "203M",
       "l": "downloads a week, npm"
      },
      {
       "n": "9,222",
       "l": "GitHub stars"
      },
      {
       "n": "54",
       "l": "agent projects use it"
      }
     ]
    },
    {
     "t": "small",
     "text": "Gid Score measures public popularity and activity, not quality.",
     "link": "How the Gid Score is calculated",
     "path": "tools/top/"
    }
   ]
  },
  {
   "id": "usage",
   "nav": "How it is used",
   "h2": "How diff is used",
   "parts": [
    {
     "t": "list",
     "items": [
      "diff is a dependency in 54 of the 6,258 public GitHub projects set up for AI coding agents that we scanned (1.1% of the 4,867 JavaScript/TypeScript ones), #25 of 408 in utilities.",
      "Counting the projects our scan samples by dependency (Solana 3,067, Ethereum and EVM 1,774, 3D and games 3,130, agent frameworks and SDKs 13,750), it appears in 242; those are left out of every share on this page.",
      "Projects that use it most often also use Vitest (70.4%), tsx (59.3%), Model Context Protocol SDK (JavaScript) (50.0%)."
     ]
    },
    {
     "t": "h3",
     "text": "By coding agent"
    },
    {
     "t": "rows",
     "rows": [
      {
       "l": "41 projects, 1.3%",
       "v": "Claude Code",
       "path": "agents/claude-code/"
      },
      {
       "l": "27 projects, 0.9%",
       "v": "GitHub Copilot",
       "path": "agents/github-copilot/"
      },
      {
       "l": "12 projects, 0.5%",
       "v": "Cursor",
       "path": "agents/cursor/"
      },
      {
       "l": "9 projects, 2.7%",
       "v": "OpenClaw",
       "path": "agents/openclaw/"
      },
      {
       "l": "6 projects, 1.3%",
       "v": "OpenAI Codex",
       "path": "agents/openai-codex/"
      }
     ]
    },
    {
     "t": "h3",
     "text": "Often used with"
    },
    {
     "t": "rows",
     "rows": [
      {
       "l": "In 70.4% of its projects",
       "v": "Vitest",
       "path": "tools/vitest/"
      },
      {
       "l": "In 59.3% of its projects",
       "v": "tsx",
       "path": "tools/tsx/"
      },
      {
       "l": "In 50.0% of its projects",
       "v": "Model Context Protocol SDK (JavaScript)",
       "path": "tools/modelcontextprotocol/"
      },
      {
       "l": "In 46.3% of its projects",
       "v": "yaml",
       "path": "tools/yaml/"
      },
      {
       "l": "In 68.5% of its projects",
       "v": "Zod",
       "path": "tools/zod/"
      },
      {
       "l": "In 42.6% of its projects",
       "v": "esbuild",
       "path": "tools/esbuild/"
      },
      {
       "l": "In 42.6% of its projects",
       "v": "jsdom",
       "path": "tools/jsdom/"
      },
      {
       "l": "In 40.7% of its projects",
       "v": "ws",
       "path": "tools/ws/"
      }
     ]
    }
   ]
  },
  {
   "id": "more",
   "nav": null,
   "spy_as": "usage",
   "h2": "More about diff",
   "parts": [
    {
     "t": "more",
     "items": [
      {
       "title": "More in Utilities",
       "path": "tools/utilities/",
       "items": [
        {
         "text": "clsx",
         "path": "tools/clsx/"
        },
        {
         "text": "date-fns",
         "path": "tools/date-fns/"
        },
        {
         "text": "PyYAML",
         "path": "tools/pyyaml/"
        },
        {
         "text": "uuid",
         "path": "tools/uuid/"
        },
        {
         "text": "yaml",
         "path": "tools/yaml/"
        },
        {
         "text": "js-yaml",
         "path": "tools/js-yaml/"
        },
        {
         "text": "glob",
         "path": "tools/glob/"
        },
        {
         "text": "Lodash",
         "path": "tools/lodash/"
        }
       ]
      }
     ]
    }
   ]
  },
  {
   "id": "alternatives",
   "nav": "Alternatives",
   "h2": "Alternatives",
   "parts": [
    {
     "t": "alts",
     "items": [
      {
       "name": "diff",
       "me": true,
       "facts": [
        "BSD-3-Clause",
        "Gid 73",
        "203M/wk"
       ]
      }
     ],
     "more": "Compare diff with another tool",
     "more_path": "tools/compare/"
    }
   ]
  },
  {
   "id": "start",
   "nav": "Get started",
   "h2": "Get started",
   "parts": [
    {
     "t": "install",
     "intro": "Install it.",
     "code": "npm install diff"
    },
    {
     "t": "gap",
     "text": "No step-by-step start for diff yet: we have not written its hand-checked card."
    }
   ]
  }
 ],
 "glance": [
  [
   "Package",
   "npm diff"
  ],
  [
   "Category",
   "Utilities"
  ],
  [
   "License",
   "BSD-3-Clause"
  ],
  [
   "Gid Score",
   "73.2"
  ],
  [
   "Rank in category",
   "#25 of 408"
  ],
  [
   "GitHub",
   "kpdecker/jsdiff"
  ],
  [
   "Last change",
   "Nov 23, 2026"
  ]
 ],
 "good": [],
 "checked_line": "From the package registry, GitHub and our scan of public agent projects; numbers update daily.",
 "logo": "https://agentgid.com/media/avatars/kpdecker.png"
}