Skip to main content
Healthcare Software

How to Build a HIPAA-Compliant Health App

Short answer: HIPAA does not certify apps and there is no badge to buy. It requires specific technical safeguards — unique user identity, role-based access, immutable audit logging, encryption in transit and at rest — plus Business Associate Agreements with every vendor touching PHI. This guide covers what that means in code and infrastructure, and where teams get cited.

By Raman Makkar, CEO & Founder··14 min read

⚖️What HIPAA actually requires of software

First, the disclaimer that matters: this is an engineering guide, not legal advice. HIPAA obligations depend on your entity type, contracts and jurisdictions, and a healthcare attorney or compliance officer should review your specific situation before launch. What follows is what the regulation means for the people building the software.

HIPAA applies to covered entities (providers, health plans, clearinghouses) and to their business associates — which includes your app and your vendors whenever the software creates, receives, maintains or transmits protected health information (PHI) on their behalf. PHI is health information linked to an identifier: names, emails, phone numbers, device IDs, IP addresses, dates more precise than a year. The moment a user record connects a name to a diagnosis, an appointment or even a symptom log, you are handling PHI.

The Security Rule is the part that governs software, and it is organized into administrative, physical and technical safeguards. Most of what developers touch is the technical safeguards, covered in the next section. But note the administrative ones, because they are where enforcement actions most often land: a documented risk analysis, workforce training, access management procedures, and incident response. An app with perfect encryption and no risk analysis is still a violation.

Not legal advice: this guide describes how HIPAA requirements map to software engineering decisions as of writing. Have a qualified healthcare attorney or compliance professional review your specific obligations before you handle real patient data.

🛡️The technical safeguards, mapped to implementation

The Security Rule defines five technical safeguard categories. Each maps to concrete engineering work, and it helps to see the mapping explicitly because auditors will ask about them in these terms.

Access control means unique user identification (shared logins are a violation by themselves), role-based permissions scoped to the minimum necessary, automatic logoff after inactivity, and emergency access procedures — a documented break-glass path for when a clinician needs records outside their normal role. Authentication is listed separately as its own safeguard: verify that a person is who they claim to be, which in 2026 practice means MFA for staff-facing surfaces at minimum, and it is treated as effectively mandatory in enforcement settlements.

Audit controls means recording who did what to which record, when, from where — in tamper-evident storage, retained for years (six years is the documentation retention baseline HIPAA uses elsewhere, and most organizations align log retention to it). Integrity controls means mechanisms to detect improper alteration of PHI — checksums, versioning, or append-only data patterns. Transmission security means encrypting PHI in motion and guarding against modification in transit.

Build these as platform capabilities, not per-feature afterthoughts. An audit log implemented as middleware that records every PHI read and write across the API is a day-one architecture decision; retrofitting it after the data model is built means touching every endpoint. Same for RBAC — a permission system designed up front is weeks; retrofitting it onto an app with role checks scattered through controllers is months.

Security Rule safeguardWhat it means in codeCommon failure
Access controlUnique user IDs, RBAC with minimum-necessary scopes, auto-logoff, break-glass pathShared staff logins; one "admin" role that can see everything
Audit controlsAppend-only log of every PHI access: who, what record, when, source IPLogs that record writes but not reads; logs users can edit
IntegrityVersioning, checksums, or append-only records so alteration is detectableDirect UPDATE with no history; no way to show a record was not tampered with
Person/entity authenticationMFA for staff, strong session management, service-to-service identityPassword-only staff login; long-lived tokens without rotation
Transmission securityTLS 1.2+ everywhere, HSTS, encrypted internal service traffic where PHI flowsPHI over plain HTTP internally; PHI in email or SMS bodies

🔐Encryption at rest and in transit — the details that matter

In transit, the bar is TLS 1.2 or higher on every surface that carries PHI — the public API, internal service-to-service calls where PHI flows, database connections, and connections to third parties. Disable legacy protocols, enable HSTS, and terminate TLS correctly at load balancers so traffic is not plaintext behind the proxy without a documented reason. Verify current guidance at build time; protocol floors move as vulnerabilities are published.

At rest, the practical standard is AES-256, which the major clouds apply by default on managed storage and databases. The part teams get wrong is not the algorithm but the scope: at rest includes primary databases, read replicas, backups, exports, search indexes, caches, queue payloads, log archives, object storage and any analytics replica. PHI in an unencrypted Redis cache or a log bucket is PHI at rest without protection, and "the database was encrypted" does not answer for it.

Key management is where audits get specific. Use a managed KMS (AWS KMS, Google Cloud KMS, Azure Key Vault) with separation of duties — the people who can read data cannot casually read keys — key rotation, and logging of key use. Application-level encryption of the most sensitive fields (SSNs, clinical notes) on top of storage encryption is a defensible extra layer that also limits what a database dump exposes.

📋Access controls and audit logging in practice

Role design deserves more care than it usually gets. Model roles on job functions — front desk, clinician, billing, admin — and scope each to the minimum necessary records and actions. Front desk sees demographics and schedules, not clinical notes. The minimum-necessary principle is a HIPAA Privacy Rule requirement, and the access control matrix is where it becomes software: a table of role against data category against action, reviewed with your compliance stakeholder, then enforced in one authorization layer rather than scattered conditionals.

The break-glass path is mandatory in spirit even where the letter says addressable: emergencies happen, and the correct design is allow access, require a reason, flag it loudly in the audit log, and review it. Blocking emergency access in software pushes clinicians to share passwords, which converts your elegant RBAC into a shared-login violation.

For audit logging, the failure modes are all about completeness and trust. Log reads as well as writes — "who viewed this patient record" is the question a privacy investigation actually asks. Write logs to append-only storage the application cannot modify (a separate account, an object-lock bucket, or a dedicated logging service), because an audit log the admin can edit is evidence of nothing. Include actor, action, record identifier, timestamp, and source, and make sure timestamps come from a synchronized clock.

What to logExample eventWhy an auditor asks
AuthenticationLogin success/failure, MFA events, password resetsAccount compromise investigations
PHI readsUser 417 viewed record 8821 at 14:03 from IP xThe core privacy question: who saw this patient
PHI writesRecord created/updated/deleted with before-value referenceIntegrity and tampering disputes
Permission changesRole granted, scope widened, account createdInsider risk and offboarding checks
Break-glass useEmergency access with stated reasonRequired review of emergency overrides
Exports and sharingBulk export, record shared externally, print/downloadBreach scoping and minimum-necessary review

☁️BAAs and hosting choices

A Business Associate Agreement is the contract HIPAA requires before any vendor handles PHI on your behalf — hosting, databases, email, error tracking, analytics, support tooling, everything. No BAA, no PHI: that is the entire rule, and it is unforgiving in both directions. Sending PHI to a vendor without a BAA is a violation even if nothing bad happens, and major vendors will simply refuse to sign one for services outside their HIPAA-eligible list.

The big three clouds all offer BAAs and publish lists of HIPAA-eligible services. The detail that bites teams: the BAA covers the eligible services only, configured correctly. AWS will sign a BAA, but if you put PHI in a non-eligible service, or misconfigure an S3 bucket, the violation is yours — the shared responsibility model applies to compliance exactly as it does to security. Healthcare-focused platforms (for example Aptible or Datica-style offerings) sit on top of the clouds and pre-wire much of this; they cost more and reduce the misconfiguration surface.

The vendors teams forget are the operational ones. Error tracking (Sentry-class tools) captures PHI in stack traces and request payloads unless you scrub it or use a BAA-covered configuration. Product analytics and session replay are worse — many will not sign BAAs at all for their standard tiers, which means the answer is architectural: keep PHI out of client-side analytics entirely. Transactional email cannot contain PHI in body or subject. Customer support chat, CDN logs, and CI artifacts all need the same question asked: does PHI ever touch this, and if so, is there a BAA?

Hosting pathBAA availableWhat you still ownTypical fit
Big-three cloud (AWS/GCP/Azure), eligible servicesYes, from the providerCorrect configuration, service selection, all application safeguardsMost teams with ops capacity
Healthcare PaaS (Aptible-class)Yes, plus pre-configured controlsApplication-level safeguards; less infrastructure workSmall teams, fast timelines
Self-managed / colocationN/A — you are the operatorEverything: physical safeguards, hardware, networkRare; large health systems only
Serverless on eligible servicesYes, within eligible listSame as cloud; watch cold-start logs and payload tracesEvent-driven components of a larger system

🚨Common violations — where teams actually get cited

Enforcement actions and breach reports cluster around a short list of unglamorous failures. Reading them is more instructive than reading the rule text, because they show what regulators actually check. The patterns below recur across public settlement announcements; the specifics of any given case are in the public record from the HHS Office for Civil Rights.

The connecting theme: the violation is rarely exotic cryptography failing. It is a missing risk analysis, an unsigned BAA, a former employee whose access was never revoked, or PHI leaking into a tool nobody classified as a vendor — process failures that software can prevent but only process can mandate.

Two deserve special attention for app builders. Web tracking technologies on authenticated or health-related pages have been an active enforcement focus — ad pixels and analytics tags on pages where health information is visible can constitute an impermissible disclosure. And lost or stolen unencrypted devices remain a steady source of reportable breaches, which is why mobile health apps enforce device-level protections and never cache PHI unencrypted on the handset.

Violation patternHow it happensThe fix
No documented risk analysisSecurity work done ad hoc, never written downAnnual documented risk analysis; update on major changes
PHI to vendors without a BAAError tracker, analytics, or support tool receives PHIVendor inventory + BAA register; scrub PHI at the client
Tracking pixels on health pagesMarketing tag manager deployed site-wideNo third-party trackers on authenticated/health surfaces
Stale accessDeparted staff accounts still activeAutomated deprovisioning tied to HR events; quarterly access review
PHI in logs or emailDebug logging of request bodies; receipts with diagnosis codesLog redaction middleware; PHI-free notification templates
Unencrypted endpointsLost laptop or phone with local PHI cacheFull-disk encryption; no unencrypted PHI at rest on devices

The pattern in public enforcement is consistent: organizations are cited for missing process — risk analysis, BAAs, access reviews — far more often than for broken encryption. Compliance is an operating rhythm, not a feature launch.

The build checklist

Everything above compresses into a checklist you can run against a build plan or an existing app. It is ordered the way a build should be: decisions first, architecture next, operations last. An item you cannot check is not automatically a crisis — it is a gap to document and schedule, which is exactly what a risk analysis is for.

Use it in both directions. Before a build, it sizes the compliance work so it lands in the estimate instead of appearing as a surprise. For an existing app, it is the skeleton of a gap assessment — and gaps found by you are fixable quietly, while gaps found by an auditor or a breach are not.

One deliberate omission: this checklist covers the software and its immediate operations. The organizational program around it — training, policies, sanctions, contingency planning — is equally required and belongs with your compliance officer or counsel. The two have to match: software that enforces least-privilege access is undermined by a policy that hands out admin credentials.

PhaseChecklist itemEvidence you should be able to show
DecideEntity status confirmed (covered entity / business associate)Legal determination in writing
DecidePHI data map: what you store, where it flowsData flow diagram including every vendor
DecideVendor inventory with BAA statusSigned BAAs on file, review dates
ArchitectRBAC matrix with minimum-necessary scopesRole-permission table, reviewed with compliance
ArchitectAudit logging as middleware, append-only storageSample log records; storage immutability config
ArchitectEncryption in transit and at rest, incl. backups and cachesConfig evidence; KMS key policy and rotation
BuildMFA on staff surfaces; session and token policyAuth configuration; session timeout evidence
BuildPHI redaction in logs, errors, analyticsRedaction tests; analytics tag audit
OperateDocumented risk analysis, updated annuallyRisk register with owners and dates
OperateIncident response runbook with breach clocksRunbook with notification timelines
OperateAccess provisioning/deprovisioning tied to HRAutomated offboarding evidence; review records
OperateScheduled log review with alertingReview cadence documentation; alert rules

💰What compliance adds to the budget, and when to hire specialists

Honest labelled ranges for the compliance premium on a health app build at US-market rates: the safeguards described here — RBAC done properly, audit logging infrastructure, encryption scope, PHI hygiene in tooling — typically add 20 to 40 percent to the engineering cost of an equivalent non-health app. On a $150,000 build, that is roughly $30,000 to $60,000. Documentation, risk analysis support and compliance-ready evidence packaging add further effort depending on how formal your buyers are; enterprise health customers will send security questionnaires that take real engineering time to answer.

When to hire a healthcare-experienced team: when the build touches PHI at all, frankly — the failure modes are non-obvious (PHI in error trackers, audit logs that skip reads, BAAs missing on a support tool) and the cost of learning them in production is measured in breach notifications. A team that has shipped HIPAA-covered software before arrives with the checklist already embodied in its defaults.

We build healthcare software with these safeguards as standard architecture, and we are direct about the boundary: engineering implements the technical safeguards and produces evidence; your counsel and compliance officer own the legal determinations. If you are scoping a health app, we can walk the data map with you and price the compliance layer honestly before you commit.

Healthcare software development servicesHealthcare app development guideScope a HIPAA-covered build with us

FAQ

Frequently Asked
Questions.

Common questions on healthcare software, answered by the Codazz engineering team.

Ask Us Anything

No. HHS does not certify software, and any vendor claiming a product is "HIPAA certified" is marketing, not regulation. Third-party audits like HITRUST or a SOC 2 report provide evidence, but neither is a HIPAA certification.

It depends on whose data it handles. Working on behalf of a covered entity or their business associates, yes. A consumer app where individuals enter their own data often falls outside HIPAA but may face FTC rules and state health-privacy laws. Get a legal determination in writing.

Some will sign BAAs for specific services in specific configurations; many will not. The answer is platform- and tier-specific and changes over time — verify directly with the vendor at build time. No BAA covering a service means PHI cannot touch it, regardless of how good the security is.

Technically it is an addressable specification, not a required one — implement it, implement an equivalent, or document why it is not reasonable and appropriate. In practice, encryption in transit and at rest is the expected baseline, and unencrypted PHI with no documented rationale is among the worst positions in an enforcement review. Treat it as required.

Designed in from the start, typically two to five extra engineering weeks on a three-to-six-month build, plus parallel time for BAA execution and documentation. Retrofitting onto an existing app is the expensive path — audit-logging and access-control rework alone can take months.

The Breach Notification Rule sets the clocks: notify affected individuals generally within 60 days of discovery, notify HHS (immediately for breaches of 500 or more individuals, annually for smaller ones), and notify media for large breaches. Verify exact thresholds with counsel and build the timelines into your incident runbook.

Building software that touches PHI?

We build healthcare applications with the safeguards designed in from day one, and we are honest about the boundary with legal compliance. Tell us what you are building; we will walk the data map and price the compliance layer.

Get a Free Quote

Tell us about your project

Or talk to an engineer