Template
KPI metrics card widget for MCP Apps
A row of key figures with their change against the previous period. Green means good news, even when the number went down.
How did the online shop do in September compared with August?
Used show_metrics
The house design: black outline, butter yellow and a marker swipe under the title.
The data it takes
| Field | Type | What it is |
|---|---|---|
| titlerequired | string | |
| period | string | Human label of the period, e.g. "September 2026" |
| metricsrequired | object[] | |
| └ labelrequired | string | |
| └ valuerequired | number | |
| └ unit | string | Shown after the value, e.g. "€" or "%" |
| └ change | number | Percent change against the previous period |
| └ lower_is_better | boolean | True when a drop is good news, e.g. churn |
Sample data
{
"title": "Monthly summary",
"period": "September 2026",
"metrics": [
{
"label": "Revenue",
"value": 48250,
"unit": "€",
"change": 12.4
},
{
"label": "Active customers",
"value": 312,
"change": 4.1
},
{
"label": "Churn",
"value": 2.3,
"unit": "%",
"change": -0.6,
"lower_is_better": true
},
{
"label": "Average order value",
"value": 154.6,
"unit": "€",
"change": -1.8
}
]
}The tool that shows it
A widget made from this template is shown by one tool. The model reads its description to decide when to call it and fills the input schema with the data. This is the definition Widgetry exports:
{
"name": "show_metrics",
"title": "Metrics",
"description": "Shows a row of key metrics (KPIs), each with a value and its change against the previous period. Use it for business, product or financial figures.",
"inputSchema": {
"type": "object",
"required": [
"title",
"metrics"
],
"properties": {
"title": {
"type": "string"
},
"period": {
"type": "string",
"description": "Human label of the period, e.g. \"September 2026\""
},
"metrics": {
"type": "array",
"items": {
"type": "object",
"required": [
"label",
"value"
],
"properties": {
"label": {
"type": "string"
},
"value": {
"type": "number"
},
"unit": {
"type": "string",
"description": "Shown after the value, e.g. \"€\" or \"%\""
},
"change": {
"type": "number",
"description": "Percent change against the previous period"
},
"lower_is_better": {
"type": "boolean",
"description": "True when a drop is good news, e.g. churn"
}
}
}
}
}
}
}More templates
- BoardColumns of cards with labels, dates and people. Like a Trello board.
- Aurora cardA featured announcement with a headline, a figure and a button, dressed differently by each design.
- 3D globeA WebGL globe with three.js that spins on its own and can be dragged, with a dot per place.
- WeatherThe weather for a place with animated SVG icons and the coming hours; each design paints its own sky.
- Progress ringsGoals as SVG rings that fill up as they appear, with their percentage.
- Area chartA series over time as an SVG curve with a gradient fill that draws itself in.
- 3D carouselCards on a ring that spins in 3D with CSS perspective. Pauses on hover.
- CountdownDays, hours, minutes and seconds to an event, ticking live with a little jump.
- MilestonesFigures that count up from zero and cascade in, animated with GSAP.
- DonutParts of a whole with Chart.js: animates in and responds to the mouse.
- Bar chartHorizontal bars with their values, in the order they arrive.
- TableRows and columns with a sticky header; the caller decides the columns.