← Back to Blog
Form Features

File Uploads in Forms: Validation, Size Limits, and What to Get Right

February 2, 2026

Patients need to upload things. Insurance cards. Photo IDs. Lab results. Prescription bottles (yes, a photo of the bottle is often the most accurate medication list you'll get). File upload fields make this possible, but without proper validation, they create more problems than they solve.

The Problems Bad File Uploads Cause

Without validation, you end up with:

  • 50MB photos taken at maximum resolution that choke your storage
  • PDFs of the wrong document entirely (you asked for insurance, they uploaded a utility bill)
  • File types your systems can't process
  • Uploads that fail silently, so neither the patient nor your staff knows something is missing

Validation catches all of this before submission.

What You Can Control

File Size Limits

Set a maximum file size (default is 10MB) that makes sense for your use case. Insurance card photos don't need to be 30MB. Most phone photos at reasonable quality are 2-5MB. Setting appropriate limits prevents storage bloat and upload failures on slow connections.

When a file exceeds the limit, the patient sees a clear message with the maximum size, not a generic error.

File Type Restrictions

Restrict uploads to the types you actually need:

  • Documents: PDF, DOC, DOCX
  • Images: JPG, PNG
  • Spreadsheets: XLS, XLSX, CSV

If you only need insurance card photos, accept JPG and PNG only. This prevents patients from accidentally uploading the wrong file type and protects against potentially harmful file formats.

Preview Before Submission

After selecting a file, patients see:

  • File name
  • File size
  • An option to remove the file and choose a different one

This preview step prevents the "oops, wrong file" problem. Patients can verify they selected the right document before submitting.

Setting It Up Right

Be specific about what you need

Don't just add a file upload field labeled "Upload Document." Say "Upload a photo of the front of your insurance card (JPG or PNG, max 10MB)." The more specific your instructions, the more likely you'll get the right file on the first try.

Use conditional logic for file uploads

Not every patient needs to upload the same documents. Use conditional logic to show file upload fields only when relevant:

  • Show insurance card upload only if the patient indicates they have insurance
  • Show referral letter upload only for referred patients
  • Show prior authorization upload only for specific procedure types

Test on mobile

Most patients will upload files from their phones, either selecting from their photo library or taking a photo directly. Test your file upload fields on mobile to make sure the experience is smooth. The upload interface is mobile-responsive, but it's worth verifying with your specific file type and size settings.

Healthcare Use Cases

Insurance cards: Front and back photos. Restrict to JPG/PNG, set a reasonable size limit, and label clearly.

Lab results and medical records: PDF uploads from patient portals or scanned documents. These tend to be larger, so adjust your size limit accordingly.

Prescription photos: A photo of the medication bottle captures drug name, dosage, prescriber, and pharmacy in one shot. Often more accurate than asking patients to type it all out.

ID verification: Driver's license or government ID for identity verification during registration.

Referral letters: PDF or document upload for specialist referrals.

Security

Uploaded files are stored with AES-256 encryption on US-hosted infrastructure. File type validation prevents malicious file uploads. Rate limiting prevents automated upload abuse. Files are accessible through the submissions dashboard with the same role-based access controls that govern the rest of your data.

File uploads are one of those features that seem simple until you implement them badly. Proper validation, clear instructions, and thoughtful size limits turn file collection from a headache into a reliable part of your intake workflow.

Ready to digitize your intake?

Start building HIPAA-ready patient intake forms in minutes.

Get Started