Radar Chart
ProRadar chart for comparing profiles across several measures, on a polygon or circular grid.
Playground
Product scores
| metric | Team A | Team B |
|---|---|---|
| Speed | 86 | 65 |
| Quality | 74 | 90 |
| Support | 60 | 70 |
| Price | 55 | 80 |
| Docs | 70 | 58 |
| Design | 92 | 61 |
Installation
Radar Chart comes with WunderUI Core and Pro, in the package from your plan. See the plans.
The charts live in their own entry point: import the chart, its card and its hooks from @wunderui/react/charts, not from @wunderui/react.
Then import what you need:
import {
RadarChart,
RadarChartProps,
RadarChartVariant,
} from "@wunderui/react/charts"Then use it:
import { RadarChart } from "@wunderui/react/charts"
const data = [
{ metric: "Speed", a: 86 },
{ metric: "Quality", a: 74 },
{ metric: "Support", a: 60 },
{ metric: "Price", a: 55 },
{ metric: "Docs", a: 70 },
]
export function ProductScores() {
return <RadarChart data={data} index="metric" series={[{ key: "a", label: "Team A" }]} label="Product scores" />
}Expected result: You should see one polygon over a five-sided grid with the five measures at its corners.
When to use
Use Radar Chart for
- A profile across several measures, where the overall shape matters (skills, quality scores)
- Comparing two or three profiles on the same axes
- Five to ten axes that share one scale
Use something else for
- Bar Chart for exact comparison of a few values
- Slope Chart for change between two points, and parallel coordinates
- Radial Chart for progress against a goal
- Bullet Chart for a measure against a target
States
Loading, empty and error keep the chart's size, so the card never jumps. Add a retry handler and the error state offers a Try again button.
Product scores
| metric | Team A | Team B |
|---|---|---|
| Speed | 86 | 65 |
| Quality | 74 | 90 |
| Support | 60 | 70 |
| Price | 55 | 80 |
| Docs | 70 | 58 |
| Design | 92 | 61 |
Ring values and series highlight
The value of each grid ring sits along the top spoke, so a polygon can be read without the tooltip; they hide on their own when the rings get too close. With several series, the polygon nearest the pointer keeps its strength and the others dim.
Product scores
| metric | Team A | Team B |
|---|---|---|
| Speed | 86 | 65 |
| Quality | 74 | 90 |
| Support | 60 | 70 |
| Price | 55 | 80 |
| Docs | 70 | 58 |
| Design | 92 | 61 |
Keyboard interactions
The plot is focusable: Arrow keys move from axis to axis and the live region reads each series value, such as Speed: Team A 60, Team B 50. Series switched off in the legend are marked hidden.
- TaborShift+Tab
- Moves focus to the plot and away from it. The plot is one tab stop; so is every legend badge.
- ArrowRightorArrowLeft
- Moves to the next or previous axis. The tooltip follows, and a live region announces the one you are on. The first press starts at the first one (Left: the last one).
- HomeorEnd
- Jumps to the first or last axis.
- Escape
- Clears the active point.
- EnterorSpace
- On a legend badge of a ChartCard: switches its series off or on. The last visible series stays on.
Behavior and motion
What the chart does on its own and what the page decides.
- Axes and polygons
- Each data row is an axis and each series entry a polygon. The index names the field with the axis name.
- Scale
- The max sets the top of the scale and defaults to a round maximum of the data. All axes share it, so keep the measures in one unit.
- Grid and fill
- The variant picks the grid (a polygon, or circles on the circular variant), the fill and whether points show.
- Empty
- The chart counts as empty when there are no data rows or the first series holds no numbers.
- Tooltip
- The tooltip takes its form from the chart's own width, like Area, Line and Bar: under 360 px it docks over the top of the chart at its full width, under 560 px it is the compact card, above that the standard card that follows the pointer.
- Loading, empty and error
- The chart keeps its size while loading, empty or failed, so the card never changes height. Add a retry handler to show a Try again button on error.
- Legend
- In a ChartCard, each series badge is a button that switches its series off, but the last visible series stays on. A legend of roles can be made static.
- Data table
- The chart renders its data as a table for screen readers, in the same order as the plot.
- Size
- The chart fills the width of its container and you set the plot height. Text never scales, so labels keep their size at every width.
Motion
The enter sequence and the hover follow the motion tokens of the library.
- Grid and polygons
- The rings grow out of the centre one after another, the spokes extend, then the polygons unfold from the centre without turning and the labels fade in. It plays on first view, after loading and when new data arrives, and can be turned off.
- Hover
- Hovering an axis highlights it and the series points glide to it. The series nearest the pointer keeps its strength, the others dim.
- Reduced motion
- With reduced motion on, the chart appears at once without the enter sequence. The tooltip and every state still work.
Anatomy
RadarChart compares several measures on one shape: each data row is an axis and each series a polygon. It suits profiles such as skills or quality scores, where the overall form matters most.
Product scores
| metric | Team A | Team B |
|---|---|---|
| Speed | 86 | 65 |
| Quality | 74 | 90 |
| Support | 60 | 70 |
| Price | 55 | 80 |
| Docs | 70 | 58 |
| Design | 92 | 61 |
- 1
Pass data with one row per axis, the field for the axis name and the series for the polygons. The max sets the top of the scale and the variant sets the grid and fill.
- 2data-slot="chart-plot"
The focusable region. Arrow keys walk its marks and the live region reads each one the way the tooltip shows it.
- 3data-slot="chart-marks"
The grid (a polygon, or circles on the circular variant) with the ring values on the top spoke, the axis labels and one polygon per series. Hovering an axis highlights it and the series points glide to it; with several series the one nearest the pointer stays and the others dim. Axis labels that would touch fall back to the hovered one.
- 4data-slot="chart-tooltip"Optional
The axis name with one row per visible series in its colour.
- data-slot="chart-message"Optional
A muted hexagon under the shimmer. The chart counts as empty when there are no data rows or the first series holds no numbers.
A table with one row per axis and a column per series.
- data-slot="chart-grid"
- data-slot="chart-scale"Optional
- data-slot="chart-axis-labels"
Best practices
- Do
Keep the same scale on every axis, with the same unit or a normalized 0 to 100 score. A radar mixes axes visually, so unequal scales distort the shape.
- Do
Limit to two or three series, and use the dots or outline variants when they overlap. Filled polygons hide each other.
- Do
Fix the axis order, with related measures next to each other. The shape changes with the order, so keep it the same across charts that are compared.
- Don’t
Don't use fewer than four axes. Three give a triangle that a bar chart shows better, and the area is not meaningful.
- Don’t
Don't read polygon area as a total. It depends on the axis order, so use the tooltip or the table for the comparison.
API reference
One table for RadarChart, listing every prop. A ChartCard around it takes its own props, and the chart works without one.
Pass data with one row per axis, the field for the axis name and the series for the polygons. The max sets the top of the scale and the variant sets the grid and fill.
| Prop | Type | Default | Description |
|---|---|---|---|
| data required | readonly ChartDatum[] | — | One object per slice / ring / axis. |
| index required | string | — | Field holding the label. |
| series required | readonly ChartSeries[] | — | One polygon per series; each row of is an axis. |
| variant | "basic-radar" | "filled-radar" | "multi-series-radar" | "circular-radar" | "radar-with-dots" | "filled-radar" | Figma variant. Default . |
| max | number | — | Top of the scale (default: a nice maximum of the data). |
| valueFormatter | ChartValueFormatter | — | |
| label | string | — | Accessible name, e.g. the card title. |
| height | number | — | Height of the plot frame in px. Default 280 (Figma small card plot). |
| state | "ready" | "loading" | "empty" | "error" | — | |
| hiddenSeries | readonly string[] | — | Labels of rows switched off in the legend: drawn faded. |
| scaleLabels | boolean | true | Shows the value of each grid ring along the top spoke. Hidden on its own when the rings sit too close for a label. |
| activeIndex | number | null | — | The active point (hovered or focused) as an index into , to control it yourself. shows none. |
| animate | boolean | — | |
| animationKey | string | number | — | |
| defaultActiveIndex | number | null | — | The point that is active at first, for an uncontrolled chart. It shows the tooltip without a pointer. |
| description | string | — | |
| emptyDescription | string | — | Text under the title in the empty state. |
| emptyTitle | string | — | Title of the message in the empty state. |
| errorDescription | string | — | Text under the title in the error state. |
| errorTitle | string | — | Title of the message in the error state. |
| onActiveIndexChange | (index) => void | — | Called with the index when the pointer or the arrow keys move to another point, and with when they leave. Use it to show the hovered value in a headline. |
| onRetry | () => void | — | Shows a Try again button in the error state and calls this when it is pressed. |
| tooltip | boolean | — | |
| width | number | — |
Notes for AI
Give your coding assistant the Markdown reference instead of screenshots.
get_component("radar-chart")The full library index for assistants is at /llms.txt.
Related components
Squad ranking by score: 6 items across W1, W8. Atlas #4 → #6; Nova #2 → #3; Orbit #1 → #1; Pulse #6 → #2; Quark #5 → #4; Vega #3 → #5 Squad ranking by score, data table name W1 W8 Atlas #4 · 46 #6 · 29 Nova #2 · 63 #3 · 53 Orbit #1 · 65 #1 · 63 Pulse #6 · 33 #2 · 58 Quark #5 · 40 #4 · 40 Vega #3 · 49 #5 · 32 Charts6 stylesProSlope ChartSlope chart for change between columns: slope, rank shift, bump chart, dumbbell and parallel coordinates.Bar chart, 12 points from Jan to Dec. Revenue from $32.0k to $58.0k, lowest $32.0k, highest $58.0k; Expenses from $18.0k to $35.0k, lowest $18.0k, highest $38.0k. Revenue and expenses, data table month Revenue Expenses Jan $32.0k $18.0k Feb $41.0k $22.0k Mar $38.0k $27.0k Apr $47.0k $24.0k May $44.0k $30.0k Jun $52.0k $28.0k Jul $49.0k $34.0k Aug $55.0k $31.0k Sep $51.0k $36.0k Oct $46.0k $33.0k Nov $53.0k $38.0k Dec $58.0k $35.0k Charts32 stylesProBar ChartBar chart for comparing values: grouped, horizontal, diverging, top-k and highlighted bars, with tooltip, keyboard navigation and a data table.Bullet chart, 3 parts: Revenue 270, Profit 22, New customers 1.7k. Quarter KPIs, data table name Actual Target poor ok good Revenue 270 250 150 225 300 Profit 22 26 20 25 30 New customers 1.7k 2.1k 1.4k 2k 2.5k Charts4 stylesProBullet ChartBullet chart for a measure against its target and qualitative ranges — horizontal, vertical or as a KPI list.