Validating and reconciling data migrated to Medplum

A Medplum migration is finished only when every in-scope source record has an explained outcome and users can complete their workflows. This page covers how to prove that with measurable evidence.

On this page

How to prove a Medplum data migration is complete

A team has loaded legacy data into a self-hosted Medplum server and must show the result is complete before cutover. Medplum defines a migration as complete only when every in-scope source unit has an explained outcome, the FHIR R4 data keeps its intended meaning, and users and integrations can perform their workflows. Those three conditions are the test this page applies, and each one needs evidence that someone other than the loading team can review. A load job that finishes without errors shows that the pipeline ran, not that the data is right. Validation is therefore a separate workstream with its own owners, acceptance criteria and sign-off, even when the same engineers build the loaders.

The effort depends on how many source units were in scope, how many were transformed rather than copied, and how much the business relies on each one. A source table that maps one-to-one onto a FHIR resource is cheap to reconcile. A legacy record that splits into several resources, or that depends on a local code set, needs a per-unit explanation for every outcome: loaded as is, loaded with a documented transformation, deliberately excluded, or rejected with a reason. Confirm with your clinical and operations owners which units they consider in scope before you estimate this work, because the exception list grows quickly when those rules are vague. Ask any partner to price validation from the manifest and acceptance criteria, not from a generic percentage of the migration budget.

Which validation checks map cleanly to Medplum and which need custom work

This table compares familiar source-side validation checks with their FHIR R4 equivalents on Medplum, and flags where custom work is needed. Read each row as a question: does the check carry over directly, does it need rebuilding in FHIR terms, or does it need a clinical reviewer. The main takeaway is that structural checks translate well, while semantic and side-effect checks need a deliberate plan.

CheckSource-side formMedplum and FHIR R4 formNeeds custom work
Record countsRow counts per table compared before and after loadResource counts by type, compared with a manifest of expected source units and their outcomesNo
Key uniquenessPrimary keys and unique natural keys in source tablesConditional updates on identifiers so reruns do not create duplicate resourcesNo
Reference integrityOrphaned foreign keys in the source databaseReference resolution across Patient, Encounter, Observation and other resources, checked after load order is completeNo
Code set membershipLocal codes checked against a code tableCoded values checked against the intended terminology bindings, with unmapped codes listed as exceptionsYes
Profile conformanceColumn types and nullability constraintsResources validated against the profiles and required elements your implementation definesYes
Document integrityFile hashes and page counts for scanned documentsBinary content hashes and DocumentReference links compared with the source file inventoryNo
Side effectsTriggers and downstream jobs in the legacy systemSubscriptions and Bots that fire on load may send messages or write data, so they must be paused, filtered or verifiedYes
Clinical meaningClinician review of charts and results in the legacy screenNo automated check confirms that a mapped diagnosis, dose or result keeps its clinical meaning; sample chart review by qualified reviewers is requiredYes

Structural, semantic and reference checks in a Medplum migration

Structural checks confirm that every migrated resource is a valid FHIR R4 instance and conforms to the profiles your deployment uses. A resource can load into Medplum and still be structurally wrong, for example a required element missing, a value outside its allowed type, or an extension that a profile does not permit. These failures often surface late, when a workflow or app reads the field, so the check belongs in the pipeline run, not only at the end.

  • Missing required elements: A Patient without a usable name or an Observation without a status is a typical failure. Validate a sample of each resource type against the profiles in use and count failures by element path.
  • Type and cardinality mismatches: A date written as free text in a dateTime field, or two values where the profile allows one, should be logged with the source record ID.
  • Profile conformance: Confirm that meta.profile values match the StructureDefinitions your apps expect. Search by profile to find resources that claim a profile they do not satisfy.
  • Load rejections: Keep the operation outcome returned for every rejected bundle entry, grouped by error code, so you can separate mapping defects from transient failures.
  • Evidence to keep: Validator version and profile package versions, the run date, failure counts per resource type and a sample of rejected payloads.

Confirm the validator and profile versions with your mapping owner before each run, because a change in profile version can move failures in or out of scope.

The sequence from manifest to dress rehearsal

The sequence turns a migration from a load that appears to have finished into one that can be shown complete. Each step produces a record that the next step checks, so every in-scope source unit ends with an explained outcome. The same sequence applies whether the source is a legacy EHR, another FHIR server or an interface engine.

  1. Build the source manifest

    Before any load runs, the migration team lists every in-scope source unit (patients, encounters, documents and other record types) with a stable source identifier and a count per type. The source owner and the data steward sign off on the list, so the scope is fixed before anyone measures success against it. The step is done when the manifest is versioned, frozen for the rehearsal, and every row can be traced back to a source key.

  2. Load in dependency order

    The loaders write FHIR resources to Medplum in the load order defined in the migration plan, so organizations, locations and practitioners exist before the records that reference them. Each load run writes a log that records the source keys it processed, the Medplum IDs it created or updated, and any rejected input. The step is done when every batch in the run has a completed log entry and no batch is left in an unknown state.

  3. Reconcile counts by resource type

    Counts in Medplum are compared with the manifest for each resource type, using the same filters that defined the source population. Differences are not netted against each other: a surplus of one type cannot cover a shortfall in another. The step is done when every resource type shows a matched count or a difference that is linked to a logged exception.

  4. Resolve references

    Every reference in the loaded data is checked to confirm it points to a resource that exists, is the intended one, and is not a placeholder. Broken or ambiguous references are sent back to the mapping or matching rules, not patched by hand in Medplum. The step is done when the reference report shows zero unresolved references or each one has a recorded decision.

  5. Log every exception with an outcome

    Each record that failed to load, loaded with a warning, or was intentionally excluded is written to an exception register with its source key, the rule that triggered it, an owner and a final outcome such as fixed and reloaded, accepted with a reason, or out of scope. Clinical and data owners review the open items with the register as the single source. The step is done when no exception is open without an owner and an outcome.

  6. Review whole charts on samples

    Reviewers examine complete charts, not isolated resources, using samples drawn in three ways: repeatable random samples with a recorded seed, and risk-based samples chosen for complex or high-impact records. Each reviewer compares the Medplum chart with the source and records whether the clinical meaning held. Medplum states there is no universal safe sample percentage, so the team agrees the sample design and its rationale before review begins. The step is done when every sampled chart has a recorded result and every discrepancy has an exception entry.

  7. Repeat the cycle in dress rehearsals

    The full sequence is run again on a copy of the source data, with the same manifest version, load order and checks, to confirm the process works without manual intervention. Timings and exception volumes from each rehearsal are compared with earlier runs to show whether the outcome is stable. The step is done when a rehearsal completes all earlier steps with the agreed acceptance criteria met and the exception register reviewed by its owners, which is the evidence used to decide on the production cutover.

Choosing whole-chart review samples without a fixed percentage

Medplum's guidance on whole-chart review is that you combine three kinds of sample and that no universal safe sample percentage exists. The sample you pick has to be defensible for your data, not copied from another migration. Start with repeatable random samples, drawn from the list of migrated Patient records with a recorded seed so the selection can be reproduced exactly. Add risk-based samples for the places where errors are most likely to hide, and keep a small judgment sample for anything the team cannot yet explain. The percentage for each stratum is a decision you record and defend, and you should confirm the exact sampling approach with the current Medplum testing and acceptance guide before you finalize your plan.

Build risk strata from what your source system actually does wrong. Typical strata include complex patients (many encounters, long medication histories, multiple coverages), merged identities where two source records were combined or split, patients whose documents or scanned files carry the clinical history, and records that came through high-volume interfaces such as ADT or lab feeds. Give each stratum its own sample so a problem concentrated in one group is not averaged away by the random draw. Record the stratum definition, the source query or rule that produced it, and the Medplum search parameters used to find the matching resources, for example a stored Patient search. Ask your team to name the owner of each stratum before review starts.

Record the seed, the source extract version, the Medplum project and the exact list of selected logical IDs in your acceptance file, so an independent reviewer can regenerate and compare the same sample. A complete chart review should check that the Patient, its identifiers and its active problems, medications, allergies and encounters match the source with an explained outcome for every difference. The reviewer should follow references from each resource to its target, confirm that any DocumentReference and Binary content opens and matches its hash, and confirm that access settings and provenance are present. Log every discrepancy as an exception with an owner and a disposition, and when a stratum shows an error pattern, widen that stratum before you sign off.

Tracking exceptions until each one has an explained outcome

Every record, resource or reference that fails a check becomes an exception, and each exception needs a named owner and a recorded outcome. The cards below describe the parts of that process that keep the exception log honest, from categorizing problems to closing them with evidence. An open exception with no outcome blocks completeness, because Medplum counts a migration as complete only when every in-scope source unit has an explained result.

Exception categories

Sort every failure into a small, fixed set of categories such as mapping gap, missing source value, failed reference, duplicate patient match, unsupported field and code translation failure. Categories let you count problems by type and see whether one defect in a mapping rule is producing hundreds of exceptions. Keep the list short enough that loaders and reviewers pick the same category for the same problem. Check that each exception records the source unit it came from, the FHIR resource affected and the validation rule that raised it.

Owner assignment

Assign each exception to one named person who can decide its outcome, usually a data steward for the source system, a mapping analyst for a rule defect or a clinical lead for a meaning question. A shared queue without an individual owner is where exceptions age without a decision. Set the rule for escalation, such as who receives an exception that stays open past your agreed review date. Confirm the owner list with your program sponsor before the first dress rehearsal.

Disposition options

Every exception ends in one of three dispositions: fixed in the mapping, loader or source data and then retested, accepted with rationale where the gap is known and the business accepts the loss or change in writing, or out of scope where the source unit was excluded by an approved scope rule. Require a written reason for each accepted or out-of-scope item, linked to the scope decision it relies on. Avoid a fourth catch-all status, since it hides unexplained items.

Clinical sign-off for meaning changes

When a fix or an accepted exception changes the clinical meaning of data, such as a dropped qualifier on a diagnosis, a collapsed medication dose or a code translated to a broader concept, a clinician must review and sign off before closure. Engineers and data analysts should not decide clinical equivalence alone. Record the reviewer, date and the specific before and after values. Ask your clinical governance group which change types require sign-off and whether that list is written into your acceptance criteria.

Retest evidence

A fixed exception is not closed until the corrected record is reloaded or regenerated and the original check passes again. Store the retest output next to the exception, including the run identifier, the manifest version it was checked against and the new result. Without retest evidence, a fix can be recorded as done while the same defect reappears in the next load. Make sure a reviewer other than the fixer confirms the retest result.

Closure rule

Write a closure rule that defines when an exception counts as explained: a disposition is recorded, the owner has signed it, any required clinical sign-off is attached and retest evidence exists for fixes. Run the rule as a report that lists all open exceptions, with the count reported at each go or no-go review. Treat any exception that fails the rule as unresolved, which blocks the migration from being declared complete. Confirm the rule with the people who will sign the cutover decision.

Medplum validation guide

How manifests, loads, checks and samples fit together

The flow starts with the source extract and its manifest, which record every in-scope unit before any mapping runs. Mapped FHIR R4 resources are loaded into Medplum, then compared against the manifest through count and reference reconciliation and semantic checks. Anything unexplained goes to the exception register, and failed items return to remediation and a re-run. Only when exceptions have explained outcomes and chart review samples pass does the migration move to a dress rehearsal and cutover gate.

Illustrative flow from source extract to the cutover gate, with a remediation loop.

Questions buyers ask about validating a Medplum migration

How much validation effort does a Medplum migration need?

Validation effort grows with source complexity and data volume, not with the size of the target platform. The main drivers are how many source systems feed the migration, how many resource types each one maps to, how many coded fields need terminology review, how many patient-matching exceptions exist, and how many documents or binaries must be checked. A single clean source with a small set of resource types takes far less checking than several legacy systems with overlapping patient records. Ask any partner to break the estimate into count reconciliation, structural and semantic checks, exception triage, whole-chart review and rehearsal runs, and to state which of these depend on your data volume. Medplum's own guidance treats a migration as complete only when every in-scope source unit has an explained outcome, so the effort is set by how many units need an explanation.

Can our own team validate a Medplum migration without a partner?

Yes, if your team has the skills and the time to run the checks independently of the people who wrote the loaders. Validation works best when a second group reviews the output, because the loader authors tend to test the paths they already expect. Your team needs FHIR R4 knowledge, the ability to query Medplum with search and read the resources it returns, scripting skills for count and reference checks, and clinical staff who can judge whether a mapped record keeps its meaning. Many organizations split the work: internal staff own source-side counts and clinical review, while an outside team runs independent structural checks and tests the manifests. DeployOpen plans, implements and tests this kind of work as a fixed-scope engagement, with scope and deliverables agreed in writing before work starts. Whichever route you choose, put the acceptance criteria in writing first.

What does a migration validation project need from clinical and data owners?

It needs named owners who can make decisions about meaning, not only confirm that data arrived. Clinical owners review whole-chart samples and decide whether a mapped problem, medication, allergy or encounter still says what the source said. Data owners confirm source counts, explain filters and exclusions, and sign off on exception categories such as unmatched patients, unmapped codes or records that were intentionally retired. Integration owners confirm which downstream systems and users depend on each resource type. Each owner should be available during the rehearsal windows, because exceptions often surface only when a reviewer reads a real chart. Agree in advance who can accept an exception, who can reject a load, and how disagreements are recorded. Without these owners, exception lists grow faster than the team can close them.

How do dress rehearsals change the migration timeline?

Dress rehearsals add a planned cycle of full loads, validation and fixes before production cutover, and each cycle adds time. Medplum's guidance treats the migration as complete only when outcomes are explained and the data keeps its intended meaning, so a rehearsal that exposes mapping gaps sends the team back to fix the mapping, reload and revalidate. The number of rehearsals depends on how many defects the first runs reveal, how long a full load takes on your target infrastructure, and how quickly reviewers can check results. Load duration is itself a planning input: Medplum's upgrade documentation notes that post-deploy data migrations can run for hours or days on large datasets, and bulk loads have their own throughput limits. Ask for a rehearsal plan that states the entry criteria for each run, the exit criteria for the final one, and the time reserved between runs for fixes.

What does a complete chart review involve?

A complete chart review follows every resource tied to one patient in the target system and compares it with the source record for that patient. Medplum recommends using repeatable samples: a random selection with a recorded seed so the sample can be reproduced, plus risk-based samples that target high-impact cases such as patients with many encounters, merged identities, or sensitive categories. Reviewers check demographics, identifiers, codes, dates, references between resources, attached documents and whether the chart is usable in the workflows that depend on it. Medplum states there is no universal safe sample percentage, so the sample size should be justified by risk, source complexity and the defect rate seen in earlier runs. Record each reviewed chart, the reviewer, the result and any exception, so the review itself becomes evidence.

How does validation evidence support a compliance review?

Validation evidence gives your compliance and security teams records they can examine, but it does not certify that the migration is compliant. Useful evidence includes the signed acceptance criteria, source and target count reconciliations, manifests, exception logs with owner decisions, sample selection seeds and reviewer results, and the rehearsal records. Medplum's compliance documentation covers frameworks such as HIPAA, SOC 2 Type II and HITRUST e1, and states that compliance is a shared responsibility between Medplum and its customers, so your own controls must be shown in your deployment. DeployOpen prepares systems, controls and evidence for compliance assessments, but it does not issue audit reports, attestations or certifications. Independent auditors and certification bodies make those determinations. Confirm with your assessor which artifacts they expect before the migration starts.

What should we ask for in a validation proposal?

Ask for a written scope that lists every in-scope source unit, the acceptance criteria for each, and the owner who accepts each exception category. The proposal should name the reconciliation methods, the structural and semantic checks, the sample design with its seed and risk rules, the number of dress rehearsals and their exit criteria, and the deliverables such as manifests and evidence packs. Ask which parts are one-time work, such as the first reconciliation and rehearsals, and which recur, such as re-checks after a Medplum upgrade or new source feeds. Ask how the partner handles exceptions that cannot be resolved before cutover, and how retesting is scheduled. DeployOpen does not publish a price list, and a quote follows from the written scope.

What usually goes wrong in migration validation and how to prevent it

Most failed Medplum migrations were not caught by the checks that were run. The failures below share a pattern: a check passed on the surface while the data, the evidence or the people behind the sign-off were not tested. Each prevention step turns a weak check into one that can be repeated and audited.

Counts that match but meaning changed

Row and resource counts can agree while codes, units, dates or status values were mapped to the wrong FHIR element. A patient with a discontinued medication can arrive as active, and the totals still reconcile. Prevention: pair every count check with semantic checks on the fields that carry clinical meaning, such as code system, status, effective dates and units, and compare a sample of source values to the stored FHIR values. Treat a matching count as a necessary condition, not proof of correctness.

References that resolve to the wrong patient

A reference such as Observation.subject can resolve successfully to a Patient, but if patient matching was wrong during load, the clinical data now sits on the wrong chart. Existence checks will not catch this. Prevention: verify that each reference resolves to a Patient whose source identifiers match the source record, using the patient-matching rules agreed in planning. Report mismatches by resource type, and sample charts where a reference was created by a merge or a fuzzy match.

Exceptions closed without rationale

Exception queues often shrink to zero because someone marked records as resolved without recording why. The migration then looks complete, but no one can explain the outcome of each source unit. Prevention: require every exception to carry an owner, a disposition such as fixed, accepted with a stated loss, or deferred, a rationale and an approver. Block closure without those fields, and review the closed log before cutover.

Samples drawn without a recorded seed

A review sample that cannot be reproduced cannot be defended to an auditor or to a clinical governance group. Re-drawing a sample after an unexpected result also hides failures. Prevention: draw repeatable random samples with a recorded seed, keep risk-based samples (for example, complex or high-volume charts) as a separate, labeled set, and store the sample list with the validation evidence. Medplum's testing guidance does not set a universal safe sample percentage, so the basis for the size should be written down and agreed.

Testing and acceptance guide

Validation run only once before cutover

A single validation pass late in the project tests one snapshot of a moving source system. Pipeline fixes, late mapping changes and new source data can all invalidate earlier results, and a one-time run leaves no evidence of stability. Prevention: run the full validation suite on every load in dress rehearsals, keep the manifests and reports from each run, and rerun the affected checks after any mapping or pipeline change. Compare results between rehearsals to confirm the errors are shrinking.

Sign-off without clinical review

Technical teams can confirm that data loaded, references resolve and counts reconcile, yet still miss problems a clinician would catch at once, such as an allergy list that reads as empty or a problem list with duplicated entries. Prevention: include clinical reviewers in whole-chart review of the sampled charts, using a written checklist for each chart, and record their findings against the acceptance criteria. Sign-off should name who reviewed what, and it should not rest on engineering checks alone.

What DeployOpen needs from your team to validate a Medplum load

Validation only proves something when the people who own the data have agreed what "correct" means before the first comparison runs. Your team needs to name a data owner for each in-scope source unit (patients, encounters, medications, results, documents and so on) and that owner must sign off the acceptance criteria: which counts must match exactly, which fields may be transformed, which records may be excluded and who approves each exclusion. Without those signatures, exception tracking has no authority to close against. Confirm early who holds that decision for each domain, because a single clinical lead rarely covers all of them.

DeployOpen also needs read access to the source systems, or scheduled exports from them, for the full duration of the work. That includes the extracts used for the manifest, the ability to rerun a source query with a recorded seed for sampling, and a named contact who can explain legacy codes and free-text fields when a sampled chart does not match. Clinical reviewers must be available to review whole-chart samples against the source, and their time should be booked before the sample list is drawn, not after. Confirm who can view protected health information for review, under what access policy, and whether reviewers must work inside your environment.

Dress rehearsals need a Medplum environment that matches the production deployment closely enough to produce a meaningful result, and your team should confirm which environment that is, including whether it is self-hosted or on Medplum Cloud, the server version and the database sizing. Ask who can provision and reset it between runs. Scope, deliverables and timelines for this work are agreed in writing before work starts, and most engagements are fixed-scope. A quote follows from that written scope, so the more precisely you can state the source units, sample rules and rehearsal count in advance, the more accurately the quote reflects the work.

How DeployOpen scopes, delivers and supports Medplum validation

DeployOpen plans and runs validation for Medplum migrations as part of a written scope, with acceptance criteria agreed before the first load. The work runs inside your own infrastructure, so the evidence your compliance and clinical teams review comes from the system that will hold the data.

How we scope

  • Agree written acceptance criteria per source unit, including which outcomes count as explained exceptions.
  • Confirm which source systems, resource types and workflows fall inside the validation scope and which are excluded.
  • Define sample rules, including the random seed method and the risk-based categories reviewers will check.

How we build

  • Build manifests and count reconciliation reports that compare source extracts with Medplum resource counts per type.
  • Write structural and semantic checks for FHIR R4 conformance, reference integrity and mapped code meaning.
  • Set up an exception register with owners, decisions and retest status, then run timed dress rehearsals before cutover.

How we hand over

  • Deliver the manifests, reconciliation reports, exception register and whole-chart review results as documented artifacts.
  • Walk your migration, clinical and compliance leads through how each acceptance criterion was tested and what evidence supports it.
  • Hand over the scripts and rules so your team can rerun the checks on later loads or after a Medplum upgrade.

How we support

  • Offer ongoing support and continuous testing as a retainer after cutover, scoped in writing.
  • Repeat reconciliation and chart review when source data changes or a Medplum version upgrade is planned.
  • Confirm with your own environment owners which Medplum version, database and hosting target the validation must cover.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.