{
 "kind": "tool",
 "slug": "recharts",
 "path": "tools/recharts/",
 "name": "Recharts",
 "maker": null,
 "density": "profile",
 "crumbs": [
  [
   "Tools",
   "tools/"
  ],
  [
   "Charts and data visualisation",
   "tools/charts/"
  ]
 ],
 "lead": "Composable React component library for building responsive charts.",
 "chips": [
  {
   "label": "Charts and data visualisation",
   "path": "tools/charts/"
  },
  {
   "label": "NPM"
  }
 ],
 "primary": {
  "label": "Copy install command",
  "copy": "npm install recharts"
 },
 "links": [
  {
   "label": "GitHub",
   "href": "https://github.com/recharts/recharts"
  },
  {
   "label": "Website",
   "href": "https://github.com/recharts/recharts"
  }
 ],
 "track": "New versions, deprecation and license changes on your dashboard",
 "verdicts": [
  {
   "key": "license",
   "label": "License",
   "value": "MIT",
   "status": "yes",
   "sub": "Use it in paid apps",
   "quote": null,
   "note": "License from npm.",
   "src": "https://github.com/recharts/recharts"
  },
  {
   "key": "maint",
   "label": "Maintained",
   "value": "Maintained",
   "status": "yes",
   "sub": "Last change Nov 24, 2026",
   "note": "Latest GitHub release Nov 23, 2026. ",
   "src": "https://github.com/recharts/recharts"
  },
  {
   "key": "pop",
   "label": "Used by agents' projects",
   "value": "576 projects",
   "status": "info",
   "sub": "#1 of 95 in its category",
   "note": "Dependency in 576 public GitHub projects set up for AI coding agents that we scanned (9.2%).",
   "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 Recharts does",
   "parts": [
    {
     "t": "prose",
     "text": "Recharts treats each part of a chart (axis, tooltip, grid, line) as its own React component, and draws the assembled chart as SVG."
    }
   ]
  },
  {
   "id": "popularity",
   "nav": "Popularity",
   "h2": "Recharts popularity",
   "parts": [
    {
     "t": "stats",
     "items": [
      {
       "n": "85",
       "of": "/ 100",
       "l": "Gid Score, #43 overall"
      },
      {
       "n": "71.4M",
       "l": "downloads a week, npm"
      },
      {
       "n": "27.7K",
       "l": "GitHub stars"
      },
      {
       "n": "576",
       "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 Recharts is used",
   "parts": [
    {
     "t": "list",
     "items": [
      "Recharts is a dependency in 576 of the 6,258 public GitHub projects set up for AI coding agents that we scanned (11.8% of the 4,867 JavaScript/TypeScript ones), #1 of 95 in charts and data visualisation.",
      "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 2,129; those are left out of every share on this page.",
      "The most used alternative in our scan is Chart.js (88 projects).",
      "Projects that use it most often also use Lucide React (92.7%), clsx (86.3%), Tailwind Merge (85.2%).",
      "It is more common in projects set up for Roo Code (19.8%) than for OpenCode (6.4%)."
     ]
    },
    {
     "t": "h3",
     "text": "By coding agent"
    },
    {
     "t": "rows",
     "rows": [
      {
       "l": "312 projects, 9.5%",
       "v": "Claude Code",
       "path": "agents/claude-code/"
      },
      {
       "l": "304 projects, 12.4%",
       "v": "Cursor",
       "path": "agents/cursor/"
      },
      {
       "l": "267 projects, 8.8%",
       "v": "GitHub Copilot",
       "path": "agents/github-copilot/"
      },
      {
       "l": "52 projects, 18.6%",
       "v": "Devin Desktop",
       "path": "agents/devin-desktop/"
      },
      {
       "l": "47 projects, 9.9%",
       "v": "Gemini CLI",
       "path": "agents/gemini-cli/"
      },
      {
       "l": "41 projects, 8.7%",
       "v": "OpenAI Codex",
       "path": "agents/openai-codex/"
      },
      {
       "l": "22 projects, 19.8%",
       "v": "Roo Code",
       "path": "agents/roo-code/"
      },
      {
       "l": "22 projects, 6.4%",
       "v": "OpenCode",
       "path": "agents/opencode/"
      }
     ]
    },
    {
     "t": "h3",
     "text": "Often used with"
    },
    {
     "t": "rows",
     "rows": [
      {
       "l": "In 92.7% of its projects",
       "v": "Lucide React",
       "path": "tools/lucide-react/"
      },
      {
       "l": "In 86.3% of its projects",
       "v": "clsx",
       "path": "tools/clsx/"
      },
      {
       "l": "In 85.2% of its projects",
       "v": "Tailwind Merge",
       "path": "tools/tailwind-merge/"
      },
      {
       "l": "In 79.7% of its projects",
       "v": "Class Variance Authority",
       "path": "tools/class-variance-authority/"
      },
      {
       "l": "In 99.0% of its projects",
       "v": "React",
       "path": "tools/react/"
      },
      {
       "l": "In 96.5% of its projects",
       "v": "Tailwind CSS",
       "path": "tools/tailwindcss/"
      },
      {
       "l": "In 71.7% of its projects",
       "v": "Radix UI",
       "path": "tools/radix-ui/"
      },
      {
       "l": "In 68.6% of its projects",
       "v": "date-fns",
       "path": "tools/date-fns/"
      }
     ]
    }
   ]
  },
  {
   "id": "profile",
   "nav": "Profile",
   "h2": "Recharts in practice",
   "parts": [
    {
     "t": "h3",
     "text": "Strengths"
    },
    {
     "t": "rows",
     "rows": [
      {
       "l": "Axis, tooltip, grid and lines are separate components",
       "v": "The README says a <code>LineChart</code> is composed of an x axis, a tooltip, a grid and line items. Each one is an independent React component. The maintainers call this separation one of the library's principles."
      },
      {
       "l": "SVG output worked inside React-pdf",
       "v": "One developer picked Recharts for client PDF reports because of its SVG output and component design. It connected to React-pdf through the <code>react-pdf-charts</code> wrapper."
      },
      {
       "l": "Positive and negative bars stack with two props",
       "v": "For a chart with positive and negative values, the same developer set <code>stackId</code> on each <code>Bar</code> and <code>stackOffset='sign'</code> on the <code>BarChart</code>. He writes that Recharts then places each bar on the correct side of the Y axis and stacks them."
      },
      {
       "l": "npm, Deno or a script tag",
       "v": "The README gives three install routes: <code>npm install recharts react-is</code>, <code>deno add recharts react-is</code>, or UMD scripts from unpkg that expose <code>window.Recharts</code>."
      }
     ]
    },
    {
     "t": "h3",
     "text": "Watch out for"
    },
    {
     "t": "rows",
     "rows": [
      {
       "l": "No built-in chart title",
       "v": "Recharts has no title component. The author notes that many users find this frustrating, and suggests Flex or similar layout to center a title over the graph."
      },
      {
       "l": "Labels can push the chart past its margins",
       "v": "The author increased the chart's margins so everything fit inside the container. He says Recharts \"seems to\" have trouble with margin calculations once labels are involved."
      },
      {
       "l": "Making charts look good takes extra work",
       "v": "In the author's view, building graphs in Recharts is easy but making them beautiful is harder. His post walks step by step through building one real graph component."
      }
     ]
    },
    {
     "t": "h3",
     "text": "A line chart with two series"
    },
    {
     "t": "tabs",
     "label": "Example",
     "items": [
      {
       "tab": "Jsx",
       "code": "<LineChart width={400} height={400} data={data}>\n  <XAxis dataKey=\"name\" />\n  <Tooltip />\n  <CartesianGrid stroke=\"#f5f5f5\" />\n  <Line type=\"monotone\" dataKey=\"uv\" stroke=\"#ff7300\" />\n  <Line type=\"monotone\" dataKey=\"pv\" stroke=\"#387908\" />\n</LineChart>"
      }
     ]
    }
   ]
  },
  {
   "id": "more",
   "nav": null,
   "spy_as": "profile",
   "h2": "More about Recharts",
   "parts": [
    {
     "t": "more",
     "items": [
      {
       "title": "Funding",
       "path": "tools/funding/",
       "items": [
        "Open Collective: https://opencollective.com/recharts"
       ]
      },
      {
       "title": "Head to head",
       "items": [
        {
         "text": "Recharts vs Chart.js",
         "note": "used together in 25 projects",
         "path": "tools/compare/recharts-vs-chartjs/"
        }
       ]
      },
      {
       "title": "Packages around it",
       "items": [
        "lucide-react: Icon components",
        "clsx: Conditional class names",
        "tailwind-merge: Tailwind class merging",
        "class-variance-authority: Variant class names",
        "@radix-ui: UI primitives",
        "zod: Schema validation"
       ]
      },
      {
       "title": "More in Charts and data visualisation",
       "path": "tools/charts/",
       "items": [
        {
         "text": "Matplotlib",
         "path": "tools/matplotlib/"
        },
        {
         "text": "Mermaid",
         "path": "tools/mermaid/"
        },
        {
         "text": "XY Flow",
         "path": "tools/xyflow/"
        },
        {
         "text": "Seaborn",
         "path": "tools/seaborn/"
        },
        {
         "text": "Plotly",
         "path": "tools/plotly/"
        },
        {
         "text": "React Chart.js 2",
         "path": "tools/react-chartjs-2/"
        },
        {
         "text": "Diagrams",
         "path": "tools/diagrams/"
        },
        {
         "text": "d3-scale",
         "path": "tools/d3-scale/"
        }
       ]
      }
     ]
    }
   ]
  },
  {
   "id": "alternatives",
   "nav": "Alternatives",
   "h2": "Alternatives",
   "parts": [
    {
     "t": "alts",
     "items": [
      {
       "name": "Recharts",
       "me": true,
       "facts": [
        "MIT",
        "Gid 85",
        "71.4M/wk"
       ]
      },
      {
       "name": "Chart.js",
       "why": "Simple HTML5 canvas-based charting library for creating interactive data visualizations.",
       "path": "tools/chart-js/",
       "facts": [
        "MIT",
        "Gid 78",
        "18M/wk"
       ]
      },
      {
       "name": "D3.js",
       "why": "JavaScript library for creating data-driven documents with powerful data visualization capabilities.",
       "path": "tools/d3/",
       "facts": [
        "ISC",
        "Gid 81",
        "36M/wk"
       ]
      },
      {
       "name": "Apache ECharts",
       "why": "Powerful interactive charting library for data visualization in browsers.",
       "path": "tools/echarts/",
       "facts": [
        "Apache-2.0",
        "Gid 75",
        "11.4M/wk"
       ]
      },
      {
       "name": "ApexCharts",
       "why": "Interactive JavaScript charting library for creating modern data visualizations.",
       "path": "tools/apexcharts/",
       "facts": [
        "SEE LICENSE IN LICENSE.md",
        "Gid 60",
        "2.9M/wk"
       ]
      },
      {
       "name": "React ApexCharts",
       "why": "React wrapper for ApexCharts with server-side rendering support.",
       "path": "tools/react-apexcharts/",
       "facts": [
        "SEE LICENSE IN LICENSE.md",
        "Gid 48",
        "1.5M/wk"
       ]
      }
     ],
     "more": "Compare Recharts with another tool",
     "more_path": "tools/compare/"
    }
   ]
  },
  {
   "id": "start",
   "nav": "Get started",
   "h2": "Get started",
   "parts": [
    {
     "t": "install",
     "intro": "Install it.",
     "code": "npm install recharts"
    },
    {
     "t": "h3",
     "text": "Rules for your agent"
    },
    {
     "t": "rules",
     "label": "Paste into AGENTS.md or CLAUDE.md",
     "text": "## Recharts\n- Install with `npm install recharts react-is` (or `deno add recharts react-is`), and keep `react-is` at the same version as the project's `react`.\n- Build charts by nesting components such as `XAxis`, `YAxis`, `Tooltip`, `CartesianGrid`, `Legend` and `Line`/`Bar` inside a chart component like `LineChart` or `BarChart`.\n- Set `dataKey` on axes and series to a field name present in the objects of the `data` array.\n- For a chart that sizes to its container, follow the site example: pass `responsive` and a `style` with `width: '100%'` and an `aspectRatio`.\n- For bars with positive and negative values, give each `Bar` the same `stackId` and set `stackOffset='sign'` on the chart.\n- There is no title component: render titles as ordinary elements outside the chart. If axis labels run outside the container, increase the chart's `margin` prop.\n- For a script-tag setup, load react, react-dom and react-is UMD builds before `Recharts.js`, then use `window.Recharts`.\n"
    }
   ]
  }
 ],
 "glance": [
  [
   "Package",
   "npm recharts"
  ],
  [
   "Category",
   "Charts and data visualisation"
  ],
  [
   "License",
   "MIT"
  ],
  [
   "Latest version",
   "v3.10.1, July 25, 2026"
  ],
  [
   "On GitHub since",
   "August 2015"
  ],
  [
   "Gid Score",
   "84.6"
  ],
  [
   "Rank in category",
   "#1 of 95"
  ],
  [
   "GitHub",
   "recharts/recharts"
  ],
  [
   "Last change",
   "Nov 24, 2026"
  ]
 ],
 "good": [
  "Used by shadcn/ui, EvilCharts, 阿里指数, 阿里数据, as listed by the source; we have not checked each one."
 ],
 "checked_line": "From the package registry, GitHub and our scan of public agent projects; numbers update daily.",
 "logo": "https://agentgid.com/media/avatars/recharts.png"
}