# apache/echarts architecture

> Architecture diagram of the GitHub repository apache/echarts, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-09). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/apache/echarts
- Repository: https://github.com/apache/echarts

## Overview

Apache ECharts is a JavaScript charting and visualization library. A caller supplies chart options through the ECharts instance; the core manages option/model state, prepares series data and coordinates, and schedules chart/component views for rendering and interaction. The graph also preserves chart families, interactive components, data transforms/tools, and the Baidu Map extension. Relationships are limited to README statements and source-index references; unsampled implementation details are not asserted.

Main entry points: [`src/core/echarts.ts`](https://github.com/apache/echarts/blob/master/src/core/echarts.ts) (ECharts instance), [`src/view/Chart.ts`](https://github.com/apache/echarts/blob/master/src/view/Chart.ts) (Chart views), [`src/model/Global.ts`](https://github.com/apache/echarts/blob/master/src/model/Global.ts) (Global model), [`src/model/Series.ts`](https://github.com/apache/echarts/blob/master/src/model/Series.ts) (Series models)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_runtime["Chart runtime"]
  node_echarts["ECharts instance<br/>[echarts.ts]"]
  node_api["Extension API<br/>[ExtensionAPI.ts]"]
  node_scheduler["Update scheduler<br/>[Scheduler.ts]"]
  node_chartview["Chart views<br/>[Chart.ts]"]
  node_componentview["Component views<br/>[Component.ts]"]
  node_renderer["ZRender renderer"]
end

subgraph group_data["Data and models"]
  node_options["Option management<br/>[OptionManager.ts]"]
  node_globalmodel["Global model<br/>[Global.ts]"]
  node_componentmodel["Component models<br/>[Component.ts]"]
  node_seriesmodel["Series models<br/>[Series.ts]"]
  node_seriesdata["Series data<br/>[SeriesData.ts]"]
  node_sources["Data sources<br/>[sourceManager.ts]"]
  node_source["Source storage<br/>[Source.ts]"]
  node_datastore[("Data store<br/>[DataStore.ts]")]
end

subgraph group_visuals["Charts and interaction"]
  node_charts["Chart families"]
  node_customchart["Custom series<br/>[CustomView.ts]"]
  node_components["Interactive components"]
  node_coordinates["Coordinate systems"]
end

subgraph group_extensions["Extensions and tools"]
  node_datatools["Data tools<br/>[index.ts]"]
  node_bmap["Baidu Map extension<br/>[BMapCoordSys.ts]"]
end

node_user(("Application developer"))

node_user -.->|"sets options"| node_echarts
node_echarts -->|"manages options"| node_options
node_echarts -->|"updates model"| node_globalmodel
node_echarts -->|"uses views"| node_chartview
node_echarts -->|"uses views"| node_componentview
node_echarts -->|"provides API"| node_api
node_globalmodel -->|"configures tasks"| node_scheduler
node_options -->|"merges options"| node_globalmodel
node_globalmodel -->|"manages components"| node_componentmodel
node_globalmodel -->|"manages series"| node_seriesmodel
node_seriesmodel -->|"exposes data"| node_seriesdata
node_seriesmodel -->|"uses coordinates"| node_coordinates
node_sources -->|"serves sources"| node_seriesmodel
node_sources -->|"creates sources"| node_source
node_sources -->|"uses storage"| node_datastore
node_chartview -->|"runs render tasks"| node_scheduler
node_chartview -.->|"renders series"| node_charts
node_componentview -.->|"renders components"| node_components
node_customchart -->|"uses chart view"| node_chartview
node_echarts -->|"uses coordinate systems"| node_coordinates
node_chartview -.->|"draws graphics"| node_renderer
node_datatools -.->|"offers utilities"| node_user
node_bmap -.->|"extends coordinates"| node_coordinates

click node_echarts "https://github.com/apache/echarts/blob/master/src/core/echarts.ts"
click node_api "https://github.com/apache/echarts/blob/master/src/core/ExtensionAPI.ts"
click node_scheduler "https://github.com/apache/echarts/blob/master/src/core/Scheduler.ts"
click node_chartview "https://github.com/apache/echarts/blob/master/src/view/Chart.ts"
click node_componentview "https://github.com/apache/echarts/blob/master/src/view/Component.ts"
click node_options "https://github.com/apache/echarts/blob/master/src/model/OptionManager.ts"
click node_globalmodel "https://github.com/apache/echarts/blob/master/src/model/Global.ts"
click node_componentmodel "https://github.com/apache/echarts/blob/master/src/model/Component.ts"
click node_seriesmodel "https://github.com/apache/echarts/blob/master/src/model/Series.ts"
click node_seriesdata "https://github.com/apache/echarts/blob/master/src/data/SeriesData.ts"
click node_sources "https://github.com/apache/echarts/blob/master/src/data/helper/sourceManager.ts"
click node_source "https://github.com/apache/echarts/blob/master/src/data/Source.ts"
click node_datastore "https://github.com/apache/echarts/blob/master/src/data/DataStore.ts"
click node_charts "https://github.com/apache/echarts/tree/master/src/chart"
click node_customchart "https://github.com/apache/echarts/blob/master/src/chart/custom/CustomView.ts"
click node_components "https://github.com/apache/echarts/tree/master/src/component"
click node_coordinates "https://github.com/apache/echarts/blob/master/src/coord/CoordinateSystem.ts"
click node_datatools "https://github.com/apache/echarts/blob/master/extension-src/dataTool/index.ts"
click node_bmap "https://github.com/apache/echarts/blob/master/extension-src/bmap/BMapCoordSys.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_echarts,node_api,node_scheduler,node_chartview,node_componentview,node_renderer toneBlue
class node_options,node_globalmodel,node_componentmodel,node_seriesmodel,node_seriesdata,node_sources,node_source,node_datastore toneAmber
class node_charts,node_customchart,node_components,node_coordinates toneMint
class node_datatools,node_bmap toneRose
class node_user toneIndigo
```

## Components

### Chart runtime

- [ECharts instance](https://github.com/apache/echarts/blob/master/src/core/echarts.ts): `src/core/echarts.ts`
- [Extension API](https://github.com/apache/echarts/blob/master/src/core/ExtensionAPI.ts): `src/core/ExtensionAPI.ts`
- [Update scheduler](https://github.com/apache/echarts/blob/master/src/core/Scheduler.ts): `src/core/Scheduler.ts`
- [Chart views](https://github.com/apache/echarts/blob/master/src/view/Chart.ts): `src/view/Chart.ts`
- [Component views](https://github.com/apache/echarts/blob/master/src/view/Component.ts): `src/view/Component.ts`
- **ZRender renderer**

### Data and models

- [Option management](https://github.com/apache/echarts/blob/master/src/model/OptionManager.ts): `src/model/OptionManager.ts`
- [Global model](https://github.com/apache/echarts/blob/master/src/model/Global.ts): `src/model/Global.ts`
- [Component models](https://github.com/apache/echarts/blob/master/src/model/Component.ts): `src/model/Component.ts`
- [Series models](https://github.com/apache/echarts/blob/master/src/model/Series.ts): `src/model/Series.ts`
- [Series data](https://github.com/apache/echarts/blob/master/src/data/SeriesData.ts): `src/data/SeriesData.ts`
- [Data sources](https://github.com/apache/echarts/blob/master/src/data/helper/sourceManager.ts): `src/data/helper/sourceManager.ts`
- [Source storage](https://github.com/apache/echarts/blob/master/src/data/Source.ts): `src/data/Source.ts`
- [Data store](https://github.com/apache/echarts/blob/master/src/data/DataStore.ts): `src/data/DataStore.ts`

### Charts and interaction

- [Chart families](https://github.com/apache/echarts/tree/master/src/chart): `src/chart`
- [Custom series](https://github.com/apache/echarts/blob/master/src/chart/custom/CustomView.ts): `src/chart/custom/CustomView.ts`
- [Interactive components](https://github.com/apache/echarts/tree/master/src/component): `src/component`
- [Coordinate systems](https://github.com/apache/echarts/blob/master/src/coord/CoordinateSystem.ts): `src/coord/CoordinateSystem.ts`

### Extensions and tools

- [Data tools](https://github.com/apache/echarts/blob/master/extension-src/dataTool/index.ts): `extension-src/dataTool/index.ts`
- [Baidu Map extension](https://github.com/apache/echarts/blob/master/extension-src/bmap/BMapCoordSys.ts): `extension-src/bmap/BMapCoordSys.ts`

### Other components

- **Application developer**

## Connections

- Application developer → ECharts instance: sets options
- ECharts instance → Option management: manages options (evidence: `src/core/echarts.ts`)
- ECharts instance → Global model: updates model (evidence: `src/core/echarts.ts`)
- ECharts instance → Chart views: uses views (evidence: `src/core/echarts.ts`)
- ECharts instance → Component views: uses views (evidence: `src/core/echarts.ts`)
- ECharts instance → Extension API: provides API (evidence: `src/core/echarts.ts`)
- Global model → Update scheduler: configures tasks (evidence: `src/model/Global.ts`)
- Option management → Global model: merges options (evidence: `src/model/OptionManager.ts`)
- Global model → Component models: manages components (evidence: `src/model/Global.ts`)
- Global model → Series models: manages series (evidence: `src/model/Global.ts`)
- Series models → Series data: exposes data (evidence: `src/model/Series.ts`)
- Series models → Coordinate systems: uses coordinates (evidence: `src/model/Series.ts`)
- Data sources → Series models: serves sources (evidence: `src/data/helper/sourceManager.ts`)
- Data sources → Source storage: creates sources (evidence: `src/data/helper/sourceManager.ts`)
- Data sources → Data store: uses storage (evidence: `src/data/helper/sourceManager.ts`)
- Chart views → Update scheduler: runs render tasks (evidence: `src/view/Chart.ts`)
- Chart views → Chart families: renders series (evidence: `src/view/Chart.ts`)
- Component views → Interactive components: renders components
- Custom series → Chart views: uses chart view (evidence: `src/chart/custom/CustomView.ts`)
- ECharts instance → Coordinate systems: uses coordinate systems (evidence: `src/core/echarts.ts`)
- Chart views → ZRender renderer: draws graphics
- Data tools → Application developer: offers utilities
- Baidu Map extension → Coordinate systems: extends coordinates
