Skip to main content
Version: 2.0.0

Dashboard Widgets

Navigate to yStore → Dashboard.

Widgets are personal, configurable panels you add to the bottom of your dashboard. Every admin can have their own widget layout — what works for a store manager differs from what a marketing director needs. Your arrangement is saved to your account and does not affect what other admins see.

Store-wide module settings

The KPI rows and section cards (Revenue Trend, Top Products, etc.) are controlled per-store from yStore → Store → Widgets. This page covers personal widgets — the ones you add yourself.


Available widgets

WidgetWhat it showsKey settings
Last OrdersMost recent orders with status and valueLimit (5–50), sort order
Last CustomersMost recently registered accountsLimit
Top ProductsBest-sellers by revenue or unitsLimit, sort by
Top CustomersHighest-value customers by lifetime spendLimit
Revenue SummaryRevenue and order count for a rolling windowRange in days (default: 30)
Total Revenue & OrdersSingle combined revenue + order count metric
Orders by StatusOrder count grouped by status
Orders by CategoryRevenue grouped by product category
Recent ProductsRecently viewed or updated products
Customer SignupsNew registrations over time
Cart AbandonmentAbandoned cart rate and count
Tax Rate StatsBreakdown of collected tax by rate
GoalCustom revenue goal tracker with progress barTarget, metric, label

Step-by-step: adding a widget

1 — Open the widget area

On the dashboard, scroll past the KPI and module sections to the widget area. Click + Add a widget.

2 — Choose a widget

A panel opens showing all available widgets grouped by category. Each card shows a preview and the available configuration options.

3 — Configure it

Fill in the widget settings. For example, the Revenue Summary widget:

┌──────────────────────────────────────┐
│ Revenue Summary │
│ ────────────────────────────────── │
│ Date range (days) [ 30 ] │
│ │
│ [ Cancel ] [ Add Widget ] │
└──────────────────────────────────────┘
WidgetWhat to configure
Revenue Summaryrange — days to include (7, 30, 90, etc.)
Last Orderslimit — rows to show (5–50)
Top Productslimit — rows; orderBy — revenue or units sold
Goallabel, target value, metric (revenue / orders)
Flow Snapshothours — look-back window; recentLimit — runs shown

4 — Add and arrange

Click Add Widget. The widget appears immediately. Then:

  • Drag to reorder
  • Resize using the handle in the bottom-right corner
  • Edit settings by clicking the ⚙ icon on the widget
  • Remove using the × button

Your layout saves automatically.

Build a focused workspace

Start with 3–5 widgets that match your daily workflow rather than adding everything.

  • Store manager: Last Orders + Cart Abandonment + Revenue Summary
  • Marketing director: Coupon Performance + Subscriber Growth + Flow Snapshot
  • Operations: Low Stock (via Inventory Alerts) + Orders by Status + Flow Health

Widget data refresh

Widget data is cached for performance. If numbers look stale:

  • Click Recalculate in the dashboard toolbar for a one-time refresh
  • Or reset from yStore → Store → Widgets → Reset Widget Cache

From the CLI:

# Reset all widget display caches
php craft yui/widget/reset

# Reset only the statistics cache (forces recalculation)
php craft yui/widget/reset --statistics

To install the default scheduled refresh cron:

php craft yui/cron/install

Building a custom widget (developers)

namespace myplugin\widgets;

use craft\base\Widget;

class MyWidget extends Widget
{
public int $range = 30;

public static function displayName(): string
{
return 'My Widget';
}

public function getSettingsHtml(): ?string
{
return \Craft::$app->view->renderTemplate(
'myplugin/widgets/my-widget/settings',
['widget' => $this]
);
}

public function getBodyHtml(): ?string
{
$data = \Craft::$app->cache->getOrSet(
"my-widget-{$this->id}-{$this->range}",
fn() => $this->fetchData(),
600
);

return \Craft::$app->view->renderTemplate(
'myplugin/widgets/my-widget/body',
['data' => $data]
);
}
}

Register it via Dashboard::EVENT_REGISTER_WIDGET_TYPES. See Extending yStore for details.