---
title: "SourceCitation"
description: "Where a piece of health information came from, in plain words, with an optional link to the fuller citation and an optional date it was last checked."
url: "https://opsinjs.pensievelabs.org/docs/components/source-citation"
source: "https://opsinjs.pensievelabs.org/docs/components/source-citation.md"
section: "Components"
status: "shipped"
kind: "component"
category: "health-communication"
reviewed: "2026-09-20"
reviewer: "engineering"
aliases: ["citation", "evidence link", "reviewed by"]
governedBy: ["trends", "safety-review"]
implemented: true
---

> Elements written as `<PascalCase … />` below are opsinjs documentation
> components. Their attributes are the content: the values they render are
> generated from `tokens/*.json` and `registry/catalogue.ts` and are
> published separately at https://opsinjs.pensievelabs.org/r/index.json and under the Reference
> section.
> `<StubNotice>` IS THE EXCEPTION, AND IT IS THE ONE TO READ. It is a
> paired element rather than a self-closing one, and the text between
> its opening and closing tags is prose an author wrote, reproduced
> below word for word. That prose is where this page says whether the
> component has been reviewed. Read the children, not only the
> attributes.

<StubNotice
  name="source-citation"
  status="shipped"
  questions="[
  &#x22;Whether printing an admission is right for a value whose provenance went missing, or whether the product should refuse to render that value at all.&#x22;,
  &#x22;Provenance is visible text near the value, not part of its accessible name, so a screen-reader user reaching the value alone does not hear its origin.&#x22;,
  &#x22;No contrast pair for the source ink or the quieter date ink has been measured on the surfaces a citation sits on.&#x22;,
]"
>
  Audited against WCAG 2.2 AA. Clinical review pending.
</StubNotice>

## Usage [#usage]

<ComponentInstall name="source-citation" unbuilt="false" importPath="@/components/ui/source-citation" registryDependencies="[&#x22;link&#x22;]" />

```tsx
import { SourceCitation } from "@/components/ui/source-citation"
```

```tsx
<SourceCitation
  source="Estimated by your watch from movement and heart rate."
  more={{ label: "Read how this is worked out", href: "/how-it-works" }}
  checkedOn="2026-03-14"
  locale="en-GB"
/>
```

## Examples [#examples]

<ComponentPreview name="source-citation" />

### A device estimate naming its own method [#a-device-estimate-naming-its-own-method]

The provenance names the device and the class of the figure, so it reads as an estimate. `more` points at the fuller accuracy document.

<ComponentPreview name="source-citation-a-device-estimate" kind="example" align="start" />

### When nobody said where it came from [#when-nobody-said-where-it-came-from]

With no `source`, the citation prints an admission rather than rendering empty. Markup you wrap a source in is taken at its word.

<ComponentPreview name="source-citation-no-source-supplied" kind="example" align="start" />

## When to use it [#when-to-use-it]

<WhenToUse
  use="[
  &#x22;Beside a health value whose provenance a reader needs to weigh it: a wearable estimate, a home device reading, a typed figure.&#x22;,
  &#x22;To attribute and link a manufacturer's accuracy document or a study you have read, rather than restating its claim as your own.&#x22;,
  &#x22;Wherever a number's origin bounds what may be said about it, so origin travels with the number where it is read.&#x22;,
]"
  avoid="[
  { case: &#x22;The message is a standing statement about the whole product, rather than the source of one value.&#x22;, instead: &#x22;disclaimer-note&#x22; },
  { case: &#x22;You are saying when a reading was taken or synced, rather than where it came from.&#x22;, instead: &#x22;relative-time&#x22; },
  { case: &#x22;You are explaining what a term means, rather than where a value came from.&#x22;, instead: &#x22;term&#x22; },
  { case: &#x22;The note is information about the content with no source to attribute.&#x22;, instead: &#x22;callout&#x22; },
]"
/>

## Clinical meaning [#clinical-meaning]

**Asserts.** Where a health value came from, in the product's own plain words, with an optional checked date and a link to the fuller source.

**Never read as.** A guarantee that the source is right, current, or checked by anybody. `checkedOn` is the date the product recorded, and a value old enough to doubt is wrapped in [RelativeTime](./relative-time.mdx) beside it.

**Colour axis.** Neither: no `status` prop and no `category` prop, and a class from either axis raises a development warning. See [Two colour axes](../health/two-colour-axes.mdx).

**Thresholds.** None. No reference range, verdict or clinical number passes through, and the product owns the words. Of the ten provenance rules in [Trends and uncertainty](../health/trends.mdx), rules 22 to 31, this component carries two, provenance in plain words at the value (rule 23) and a manufacturer's claim attributed rather than restated (rule 27). The other eight stay the caller's, and it renders a wrong string as readily as a right one. opsinjs ships no source, date, DOI or study. See [Safety review](../health/safety-review.mdx).

<SafetyCallout severity="attention" evidence="opinion">
  Never restate a manufacturer's accuracy figure as your own, and never invent one. Attribute the claim and link it through `more`, in the manufacturer's own terms.
</SafetyCallout>

## Accessibility [#accessibility]

The audit found no axe violation, missed target size, hidden focus or loss at 320px reflow. Both lines are set at `text-opsin-footnote`, a rem from the generated ramp and never a `px` size, in `--foreground` for the source and `--muted-foreground` for the date, with no raw colour literal or ramp step. `more` carries the label and the href together, so a link cannot be added without a label, and an external href adds an off-screen "opens in a new tab". The link is not inside a sentence, so it re-adds `--opsin-target-minimum` on both axes. See [Accessibility](../foundations/accessibility.mdx). It reflows at 200% text with no fixed height, and `min-w-0` with `wrap-break-word` breaks a long device name.

**Residual items.**

* The source line, the last-checked time and the fuller-citation link render as loose siblings with no programmatic group binding them. Reading order keeps the association, so this is not an AA failure.
* The "Last checked on" chrome is always English while the date follows the caller's `locale`, and when they differ the localised date carries no `lang` seam yet, per ADR 0005.

<KeyboardTable
  name="source-citation"
  rows="[
  {
    keys: &#x22;Tab&#x22;,
    action: &#x22;Moves to the link, when there is one&#x22;,
    notes: &#x22;The citation is text, not a tab stop. The link is its only focusable element.&#x22;,
  },
  {
    keys: &#x22;Shift + Tab&#x22;,
    action: &#x22;Moves back out of the link&#x22;,
    notes: &#x22;Reverse order matches visual order. The link is last.&#x22;,
  },
  {
    keys: &#x22;Enter&#x22;,
    action: &#x22;Follows the link&#x22;,
    notes: &#x22;Only when a link is present. An ordinary anchor, so Enter and not Space.&#x22;,
  },
  {
    keys: &#x22;Space&#x22;,
    action: &#x22;Scrolls the page, as it does anywhere else&#x22;,
    notes: &#x22;Nothing here captures Space or activates on it.&#x22;,
  },
]"
/>

<ContrastReport component="source-citation" />

## Props interface [#props-interface]

<PropsTable name="SourceCitationProps" />

`source` is typed optional but required by the contract, so the missing state can render. `checkedOn` is a strict `YYYY-MM-DD` string or epoch milliseconds, both pinned to UTC. A value that is not a real calendar date is refused, not rendered as a plausible wrong one.
