talira

Lightweight Charts

Tiny, fast HTML5 canvas library for interactive financial charts

open sourceApache-2.0free

Lightweight Charts is TradingView's open source JavaScript library for interactive financial charts on web pages, drawn on HTML5 canvas and about 35 KB in size. It draws candlestick, bar, line, area, baseline and histogram series, streams real-time updates without reloading, stays responsive with thousands of bars, and can be styled fully or extended with custom plugins (a plugin catalog and examples are in its docs). It installs from npm or a CDN, and the repository ships two Agent Skills for AI coding assistants. It's Apache-2.0 licensed, with an attribution requirement.

Problems it solves

  • show stock or crypto price data as an interactive candlestick chart on my site
  • a small charting library for financial time series that won't slow my page
  • replace static chart images with interactive ones

Features

  • candlestick, bar, line, area, baseline and histogram series
  • about 35 KB on HTML5 canvas
  • real-time streaming updates
  • custom series and primitive plugins
  • themes and full styling control

Limitations

  • The licence requires showing TradingView's attribution notice and a link to tradingview.com on the page or app that uses it.1

Alternatives

The same job

These do what Lightweight Charts does.

  1. Chart.js Simple yet flexible JavaScript charting for the web
  2. ChartGPU A WebGPU charting library for millions of points and real-time streaming
  3. Apache ECharts Open source JavaScript library for interactive charts and visualization
  4. Chartkick Create beautiful JavaScript charts with one line of Ruby
  5. Plotly.js Open source JavaScript library for interactive charts, 3D graphs and maps
  6. ApexCharts Interactive SVG charts for the web, free under M revenue

Compare Lightweight Charts with the top 3