How to Build a HIPAA‑Compliant Website: Real‑World Scenarios That Show What to Do (and What to Avoid)

Check out the new compliance progress tracker


Product Pricing Demo Video Free HIPAA Training
LATEST
video thumbnail
Admin Dashboard Walkthrough Jake guides you step-by-step through the process of achieving HIPAA compliance
Ready to get started? Book a demo with our team
Talk to an expert

How to Build a HIPAA‑Compliant Website: Real‑World Scenarios That Show What to Do (and What to Avoid)

Kevin Henry

HIPAA

March 19, 2025

8 minutes read
Share this article
How to Build a HIPAA‑Compliant Website: Real‑World Scenarios That Show What to Do (and What to Avoid)

Building a HIPAA‑compliant website is about protecting Protected Health Information (PHI) end to end—technology, workflows, and people. The goal is to reduce risk while enabling care delivery and patient self‑service.

The scenarios below show what to do (and what to avoid) at each stage. You will see how encryption, access controls, Business Associate Agreements (BAAs), Vulnerability Assessments, and strong Compliance Management practices work together.

Implement SSL Certification

Real‑world scenario

You launch an online intake form that collects symptoms and insurance details. Patients use public Wi‑Fi at coffee shops and airports. Without strong TLS, attackers can intercept PHI in transit.

What to do

Use TLS 1.2+ (preferably TLS 1.3) with modern cipher suites and enable HTTP Strict Transport Security (HSTS). Redirect all HTTP traffic to HTTPS, and block mixed content so every script, image, and API call is encrypted.

Secure cookies with the Secure and HttpOnly flags, set SameSite appropriately, and rotate certificates automatically before expiry. Monitor for certificate errors and pin APIs when feasible to reduce man‑in‑the‑middle risk.

What to avoid

  • Self‑signed or expired certificates on production systems.
  • Leaving legacy TLS/SSL protocols enabled or allowing weak ciphers.
  • Loading assets over HTTP (mixed content) on otherwise secure pages.

Implementation checklist

  • Obtain a trusted certificate and automate renewal.
  • Force HTTPS and enable HSTS with preload where appropriate.
  • Harden TLS versions and ciphers; disable TLS 1.0/1.1.
  • Set Secure, HttpOnly, and SameSite on session cookies.
  • Scan regularly and remediate findings as part of Vulnerability Assessments.

Ensure Data Integrity

Real‑world scenario

A patient’s lab values are posted to a portal. A race condition during an update writes partial data, and the chart shows the wrong range, risking clinical decisions.

What to do

Protect integrity at multiple layers. Use input validation, transaction controls, optimistic locking, and database constraints to prevent partial writes. Store cryptographic hashes or digital signatures for critical records so you can detect tampering.

Implement append‑only audit logs with user, timestamp, and action. Keep version history for sensitive artifacts (e.g., consent forms) and use WORM or immutable storage as needed. Pair integrity controls with Data Encryption at rest to guard PHI comprehensively.

What to avoid

  • Direct database edits without audit trails or approvals.
  • Overwriting records instead of versioning changes.
  • Mixing test and production data or using free‑text fields for structured PHI.

Implementation checklist

  • Define integrity requirements per data type (orders, results, consents).
  • Use checksums/signatures for critical PHI and verify on read.
  • Enable detailed, tamper‑evident audit logging and alerts.
  • Adopt strong input validation and concurrency controls.

Enforce Access Management

Real‑world scenario

Front‑desk staff needs scheduling tools, clinicians need clinical data, and billing needs claims. If everyone gets the same role, the “minimum necessary” standard is violated.

What to do

Adopt Role‑Based Access Control (RBAC) with least privilege. Provision roles for front desk, clinician, billing, and admins; grant only what each role needs. Require Multi‑Factor Authentication (MFA) for staff, administrators, and vendors accessing PHI.

Use unique user IDs, short session lifetimes, revocation on termination, periodic access reviews, and just‑in‑time elevation for rare tasks. Provide a monitored “break‑glass” path for emergencies with documented justification.

What to avoid

  • Shared or generic accounts (e.g., “nurse1,” “admin”).
  • Long‑lived tokens and idle sessions without re‑authentication.
  • Storing secrets in code repositories or browsers’ insecure storage.

Implementation checklist

  • Map users to RBAC roles and implement least‑privilege policies.
  • Enforce MFA across workforce and privileged accounts.
  • Automate joiner‑mover‑leaver processes to prevent orphaned access.
  • Log all access to PHI and review regularly.

Establish Data Backup and Recovery

Real‑world scenario

Ransomware encrypts your database on a Friday night. Without recent backups and a tested runbook, the portal stays down for days and PHI may be lost.

What to do

Define Recovery Time Objective (RTO) and Recovery Point Objective (RPO). Follow the 3‑2‑1 rule: three copies of data, on two different media, with one offsite/immutable. Encrypt backups at rest and in transit, and separate encryption keys from backup locations.

Test restores on a schedule, validate integrity, and document step‑by‑step recovery. Use runbooks, drill exercises, and monitoring that alerts you to failed jobs or unusual backup patterns.

Ready to simplify HIPAA compliance?

Join thousands of organizations that trust Accountable to manage their compliance needs.

What to avoid

  • Storing backups on the same network segment as production systems.
  • Unencrypted or untested backups and one‑time snapshots.
  • Lack of documented recovery procedures and roles.

Implementation checklist

  • Set clear RTO/RPO targets per system handling PHI.
  • Automate encrypted backups with immutability/air‑gap options.
  • Perform periodic restore tests and record evidence for Compliance Management.
  • Monitor jobs and alert on anomalies or failures.

Secure Business Associate Agreements

Real‑world scenario

You plan to use a cloud form builder, SMS vendor, and analytics tool. Each may process PHI directly or indirectly, creating Business Associate relationships.

What to do

Execute Business Associate Agreements (BAAs) with every vendor that handles PHI, including subcontractors. Confirm security controls, breach‑notification timelines, permitted uses/disclosures, encryption requirements, data retention, and termination handling.

Assess vendors’ posture via questionnaires and audits, and capture artifacts (BAAs, reports, attestations) in your Compliance Management system. Limit data sharing to the minimum necessary and use de‑identification when analytics do not require PHI.

What to avoid

  • Using consumer‑grade tools (email, chat, file‑sharing) without BAAs.
  • Vague contracts that omit security obligations and subcontractor flow‑down.
  • Allowing vendors to reuse PHI for unrelated product analytics or marketing.

Implementation checklist

  • Inventory all vendors and data flows that involve PHI.
  • Negotiate and countersign BAAs; verify subcontractor coverage.
  • Define breach response roles and notification timelines.
  • Store BAAs and evidence centrally for audits.

Conduct Regular Security Audits

Real‑world scenario

Your team ships features weekly. New code and dependencies introduce risk faster than annual checklists can catch.

What to do

Run continuous Vulnerability Assessments: static and dynamic application tests, dependency and container scans, and configuration baselines. Schedule third‑party penetration tests and conduct a Security Rule risk analysis that maps threats to controls.

Prioritize remediation by severity and exploitability, track fixes to closure, and keep evidence (tickets, reports) for Compliance Management. Review logs and alerts for anomalous access to PHI, and feed findings into ongoing risk treatment plans.

What to avoid

  • One‑time scans without remediation or verification.
  • Ignoring cloud misconfigurations, secrets exposure, or default settings.
  • Lack of documented risk analysis and management plans.

Implementation checklist

  • Define an audit calendar (quarterly internal, annual external tests).
  • Automate code, dependency, and infrastructure scanning in CI/CD.
  • Maintain a risk register and corrective action plans.
  • Validate fixes and keep audit evidence organized.

Provide Employee Training

Real‑world scenario

A staff member receives a phishing email that looks like an EHR login. They enter credentials, and an attacker gains access to PHI.

What to do

Deliver onboarding and annual HIPAA training tailored to roles. Cover secure handling of PHI, phishing recognition, incident reporting, clean‑desk and screen‑lock habits, and why MFA matters. Include tabletop exercises and quick refreshers when policies change.

What to avoid

  • One‑size‑fits‑all, click‑through modules with no practical scenarios.
  • Policies that exist on paper only, with no coaching or reinforcement.
  • No repercussions or feedback loop after repeated risky behavior.

Implementation checklist

  • Role‑specific training plans and clear acceptable‑use policies.
  • Routine phishing tests and just‑in‑time micro‑lessons.
  • Documented attendance and acknowledgments for Compliance Management.
  • Easy reporting path for suspected incidents or data mishandling.

Conclusion

A HIPAA‑compliant website combines strong encryption, proven integrity controls, RBAC with MFA, resilient backups, signed BAAs, disciplined audits, and continuous training. Treat compliance as an ongoing program—embed these practices into daily operations to protect PHI while delivering a safe, trustworthy experience.

FAQs.

What are the key security measures for a HIPAA-compliant website?

Encrypt data in transit and at rest, enforce RBAC with MFA, maintain tamper‑evident audit logs, validate inputs and integrity, back up and test restores, run continuous Vulnerability Assessments, and monitor access to PHI. Document everything in your Compliance Management program.

How do Business Associate Agreements affect HIPAA compliance?

BAAs contractually bind vendors that handle PHI to HIPAA responsibilities. They define security controls, permitted uses, breach notifications, retention, and termination steps. Without executed BAAs (including subcontractor flow‑down), you risk noncompliance even if your internal controls are strong.

What role does employee training play in maintaining compliance?

Training turns policy into practice. It teaches staff how to safeguard PHI, spot phishing, use MFA, follow the minimum‑necessary standard, and report incidents promptly. Measured, role‑specific training reduces human error—the most common cause of breaches.

How often should security audits be conducted?

Continuously scan code and infrastructure, review logs weekly, run internal audits quarterly, and commission external penetration testing at least annually or after major changes. Update your risk analysis whenever systems, data flows, or threats materially change.

Share this article

Ready to simplify HIPAA compliance?

Join thousands of organizations that trust Accountable to manage their compliance needs.

Related Articles