Home / Tools

Kaplan–Meier curve generator

Updated 2026-09-25 · TrialCurve methods team

Make a publication-style Kaplan–Meier plot in seconds. Paste your data below and you get survival curves with censor ticks, a numbers-at-risk table, the median per arm, the log-rank p-value, the Cox hazard ratio with 95% CI, and RMST. Download as SVG or PNG. Everything runs in your browser, so the data never leaves your computer.

Paste one row per patient as arm,time,event (event: 1 = event, 0 = censored). You can paste from Excel, R or SAS output, or load the example.

Data format

One row per patient, three columns: the group name, the follow-up time, and whether the event happened (1) or the patient was censored (0). Time can be in any unit, as long as it is the same unit throughout. A header row is optional.

arm,time,event
Control,2.3,1
Control,18.0,0
Drug,6.4,1
Drug,24.0,0

What the generator computes

Only have a published figure?

If you have the curve but not the data, reconstruct the patient-level data from the figure, then paste the downloaded CSV here to re-plot, restyle or combine it.

Kaplan–Meier curves in other software

FAQ

How do I create a Kaplan-Meier curve online for free?

Paste one row per patient (group, time, event) into the generator on this page and click Draw. It produces the curve, numbers at risk, medians, log-rank p, hazard ratio and RMST, and lets you download SVG or PNG.

Is my data uploaded anywhere?

No. The Kaplan–Meier generator runs entirely in your browser.

Can I make a Kaplan-Meier curve in Excel?

Not directly. You can compute the product-limit estimate by hand in a spreadsheet and plot a step chart, but a dedicated tool (or R/Python/Prism) is faster and less error-prone.

Reconstruct IPD from your own figure. Upload a Kaplan–Meier plot and get curves, numbers at risk, pseudo-IPD, hazard ratios and a validation pack. Three figures a month are free.

Try the live demo Browse trial data API docs