Smart Home Assistant
HA 2024.1+Zero-configHACS Frontend

Trading212 Lovelace Card

A free custom Lovelace card for Home Assistant that displays your Trading212 portfolio — account value with a 7-day sparkline, today's P&L, positions with per-instrument trends, and pies. Works automatically once the Trading212 integration is installed; no manual sensor mapping required.

Requires the Trading212 integration. The card reads sensors created by the integration — install that first if you haven't already. Integration setup guide →

Cards at a glance

CardYAML typeWhat it shows
Healthcustom:investment-health-cardPortfolio value with 7-day sparkline, today's P&L, and top/bottom movers.
Portfoliocustom:investment-portfolio-cardAll-in-one: account overview, positions list, and pies — one card.
Overviewcustom:investment-overview-cardAccount stat grid with daily movers — no positions or pies.
Positionscustom:investment-positions-cardScrollable positions list with per-instrument sparklines.
Piescustom:investment-pies-cardScrollable pies list with goal progress and dividend breakdown.

Screenshots

Trading212 Health card — portfolio value with 7-day sparkline and daily P&L
Trading212 Overview card — account stat grid with daily movers
Trading212 Portfolio card — all-in-one overview, positions, and pies
Trading212 Positions card — scrollable positions list
Trading212 Positions card expanded — full positions detail with sparklines
Trading212 Pies card — scrollable pies list with goal progress
Trading212 Pies card expanded — full pie detail with dividends

Installation

Via HACS (recommended)

  1. 1

    Open HACS → Frontend, then click the ⋮ menu (top-right) → Custom repositories.

  2. 2

    Paste https://github.com/Smart-Home-Assistant-UK/lovelace-trading212-card as the URL, set Category to Plugin, and click Add.

  3. 3

    Find Trading212 Lovelace Card in the HACS Frontend list and click Download.

  4. 4

    Reload your browser.

  5. 5

    Add a card to your dashboard, search for investment, and choose any card type.

Manual install

  1. 1

    Download investment-card.js from the latest release and copy it to config/www/.

  2. 2

    Add it as a Lovelace resource: go to Settings → Dashboards → Resources → Add Resource, enter /local/investment-card.js, and set type to JavaScript module.

  3. 3

    Reload your browser, then add a card as normal.

Quick-start YAML

All cards auto-discover your sensors — no entity IDs to configure. Copy any of the examples below and paste it into the HA card editor (YAML mode).

Health card (zero-config)

type: custom:investment-health-card

Portfolio card (zero-config)

type: custom:investment-portfolio-card

Positions card with custom prefix

type: custom:investment-positions-card
prefix: sensor.my_broker_

Portfolio card — overview only

type: custom:investment-portfolio-card
show_positions: false
show_pies: false

Configuration reference

OptionDefaultCardsDescription
prefixsensor.trading212_AllSensor entity prefix for auto-discovery. Change only if you use a custom integration prefix.
max_height400pxPositions, PiesMax height of scrollable lists before the card becomes scrollable.
show_overviewtruePortfolioShow or hide the account overview section in the Portfolio card.
show_positionstruePortfolioShow or hide the positions section in the Portfolio card.
show_piestruePortfolioShow or hide the pies section in the Portfolio card.

Don't have Trading212 yet?

Sign up with this link and we both get a free share worth up to £100.

Get a free share →

Step 1

Trading212 Integration →

Install the custom component that exposes your portfolio as HA sensors.

Full guide

Lovelace Card Setup Guide →

Dashboard layout tips, card configuration walkthrough, and theming.