When could you actually retire? Drop a single script tag into your site, then use <retirement-calc-rmd> as a custom HTML element anywhere on the page.
Sibling of <retirement-calc-spend> — same engine, different question.
Pick colors that match your site, then copy the CSS snippet at the bottom.
retirement-calc-rmd {
--rc-accent: #4f8ec9;
--rc-bg: #ffffff;
--rc-surf: #f7f9fc;
--rc-text: #1a1f2e;
}
Drop this into your HTML:
<script src="https://app.retirementscenario.com/embed/v1/rmd.js"></script>
<retirement-calc-rmd></retirement-calc-rmd>
Or pre-seed values relevant to your audience:
<retirement-calc-rmd
plan-type="household"
current-age="62"
current-balance="1400000"
contrib-annual="20000"
retirement-age="65"
return-pct="6.5">
</retirement-calc-rmd>
| Attribute | Default | Range |
|---|---|---|
current-age | 60 | 40 – 85 |
current-balance | 800000 | 0 – 5,000,000 (pre-tax: 401k + traditional IRA combined) |
contrib-annual | 15000 | 0 – 50,000 (assumed until retirement-age, then stops) |
retirement-age | 65 | currentAge – 80 (when contributions stop) |
return-pct | 7.0 | 4.0 – 10.0 (nominal annual %) |
plan-type | single | single or household |
refsrc | (none) | partner attribution tag |
Override CSS custom properties on the host:
retirement-calc-rmd {
--rc-accent: #ff6b35; /* primary color */
--rc-bg: #ffffff; /* card background */
--rc-surf: #f7f9fc; /* sub-surface (result area) */
--rc-text: #1a1f2e;
--rc-muted: #6a7280;
--rc-border: rgba(20,30,50,0.10);
--rc-radius: 12px;
}
The element emits two custom events you can listen to:
document.querySelector('retirement-calc-rmd')
.addEventListener('rc-calculated', (e) => {
console.log('First RMD at age:', e.detail.firstRMDAge);
console.log('First RMD amount:', e.detail.firstRMD);
});
document.querySelector('retirement-calc-rmd')
.addEventListener('rc-cta-clicked', (e) => {
console.log('User clicked CTA to:', e.detail.url);
});