Building custom OpenEMR forms with Layout Based Forms

Layout Based Forms let a practice build specialty intake, assessment and encounter forms in OpenEMR without writing code, if the fields, reuse and upgrade path are planned first.

On this page

When a practice needs custom OpenEMR forms with Layout Based Forms

A specialty clinic usually discovers the problem at the intake desk: the standard encounter screen asks for nothing the specialty needs, while the fields it does need, such as a functional score, a referral reason or a set of measurements, end up typed into free-text notes. Layout Based Forms are OpenEMR's way to define a structured form for that workflow without writing code. In practice, you define the form's fields and the groups that organize them, then use the form in the clinical workflow. The point is to capture the data as data, so it can be searched, reported and shown elsewhere, rather than as narrative text.

Choose Layout Based Forms when the need is a structured form with fields that a non-developer can maintain, and when the content should be reusable in reports and the patient portal. Use a custom module instead when the requirement involves new logic, new screens or integrations that a form definition cannot express. A template library suits reusable note text, not structured capture, and a standard form is the right answer when OpenEMR already collects the data. Before you commit, confirm with your OpenEMR version which field types, group options and portal and report behaviors exist, because these change between releases. Check the release notes on the OpenEMR releases page and the platform requirements for your version, including the PHP version and the database it runs on.

Treat the form decision as a design task with an owner. List the fields your clinicians need, mark which ones feed reports or the portal, and identify who will edit the form after go-live. Then test one form end to end in a non-production copy: enter a sample encounter, run the report you expect to use, and confirm the output matches what the clinicians asked for. Record each form's field list and purpose, because that record is what you will check after every upgrade to confirm the forms still behave as designed.

Which form approach fits which requirement

This table compares Layout Based Forms, clinical note templates, custom modules and the standard built-in forms against the decisions a practice faces most often. Read each row against your own requirement, then confirm the capabilities marked for checking in your OpenEMR version before you commit to an approach.

RequirementLayout Based FormsCustom moduleStandard built-in forms
Specialty intake or assessment with fields, groups and simple repeatsWell suited. Built from the admin interface without writing code, so most field and group changes stay out of core files.Possible but heavier. Needed mainly when the form logic goes beyond what the layout editor expresses.Only if an existing built-in form already covers the fields. Changing its content usually means editing shipped files.
Build and maintenance effortLower up front. Ongoing effort comes from reviewing field changes after each upgrade and testing form output.Higher. Code must be written, packaged, registered and kept compatible with each release.Lowest to adopt, but any customization you add to shipped forms raises the cost of every upgrade.
Who can change the formStaff with form-building rights can change layouts, subject to your access settings. Confirm which admin role can edit forms in your version.Developers only, with a release process for every change.Developers or vendor-approved changes only, since shipped forms are not meant to be edited in place.
How data reaches reports and the portalStored as form data that reports can use. Confirm in your version whether a given field appears in patient portal views before you promise it.Depends on how the module writes data. Reporting and portal access must be designed and tested separately.Standard reports and portal views cover the built-in fields. Anything beyond them needs a custom report or query.
Upgrade riskModerate. Layouts persist across upgrades, but field behavior and rendering should be retested after each release on your version line.Moderate to high. Module APIs and hooks can change, so each release needs a compatibility check.Low for unmodified forms. High if core files were edited to match local workflows.
Clinical decision logic or calculationsLimited to what the layout editor supports. Confirm calculation or conditional display options in your version.Best fit when logic is complex, auditable and version controlled.Not available beyond what the shipped form does.
Structured note content for a single encounterGood when the content must be stored as discrete fields for reporting.Possible, but rarely needed for this purpose.Good for standard encounter documentation already shipped.
Shared documentation templates for narrative notesNot the main tool. Clinical note templates suit repeatable narrative text that clinicians edit.Unnecessary unless templates must integrate with custom workflow logic.Limited to what ships; local template libraries are more flexible.

How to build a Layout Based Form step by step

This sequence takes a specialty form from clinical requirements to a documented, tested configuration that a practice can carry through OpenEMR upgrades. Each step ends with a check that someone other than the builder can review.

  1. Define clinical content and data owners

    Start by writing down what the form must capture, why each item matters to care or billing, and who is accountable for its content. A clinical lead signs off on the questions and answer options, and an administrator names the owner who approves later changes. Keep the list in a short requirements document that names each field's purpose. The step is done when the clinical lead and the owner have both signed the document, and no field exists without a stated purpose.

  2. Map fields, groups and data types

    Translate the requirements into a field map: each question, its input type, its required or optional status, its grouping on the page and its answer list. Note which fields duplicate data OpenEMR already stores, such as demographics, so the team avoids double entry. Review the map against the requirements to confirm every item is covered and no group holds unrelated questions. The check is a written map that a clinician can read without seeing the builder's notes.

  3. Build the form in a non-production instance

    Create the form in Layout Based Forms on a test OpenEMR instance that matches the production version, PHP version and database. Enter fields and groups exactly as mapped, and record each setting in a configuration log that lists field names, options and any layout choices. Confirm the test instance is separate from patient data before work starts. The step is complete when the form loads without errors and the configuration log matches the map one to one.

  4. Test entry and display with test patients

    Enter the form against test patient records covering typical, empty, edge and invalid answers. Check that saved values reappear on reopening, that required fields block saving when they should, and that the form renders correctly in the encounter view the clinicians use. Ask a clinician to complete the form from start to finish, and record the issues they raise. The check passes when the clinician signs off on a test run and every raised issue is either fixed or logged for a decision.

  5. Decide report and portal exposure

    Decide which saved answers should appear in reports or in the patient portal, and which should stay internal to clinical staff. Each exposure is a disclosure decision, so the privacy or compliance owner should approve it in writing before the form goes live. Check the portal and report output with test records to confirm that only approved fields appear. The step is done when the approved list of exposed fields is recorded and the test output matches it.

  6. Set access for the form

    Restrict who can view, enter and change the form using OpenEMR's access control settings, mapping each role to the actions it needs. Test the permissions with one test account per role, including a front desk account, to confirm each role sees only what it should. Record the role matrix alongside the configuration log. The check is a completed matrix with test results for each role, and an administrator who reviews it.

  7. Move to production and document for upgrades

    Apply the tested configuration to production through a recorded change, with the approved map, configuration log, test results and access matrix attached. After go-live, document how the form is stored, which settings it depends on, and the steps to recreate it on a new instance. Before each OpenEMR upgrade, repeat the test patient run on a staging copy and compare the output with the record. The step is done when the change record is filed and the upgrade check procedure is written for the next person.

How a custom form moves from design to production

The path starts with a written requirement that names the workflow, the users and the data the form will hold. The form is then designed in Layout Based Forms and built on a test instance, where clinical staff review it before anyone decides whether it appears in reports or the patient portal. Two decision points check access control and PHI exposure, and an upgrade check runs before production release and again on every later OpenEMR upgrade, looping back to testing whenever the form breaks.

Decision path for moving a Layout Based Form from requirement to production, with upgrade checks.

Where form data goes after a clinician saves it

The encounter record and chart view is the first and most direct destination. A saved form value is stored with the encounter, and the clinician, the care team and anyone with chart access under the practice's access rules can usually see it when they open that encounter. Confirm this in your own build rather than assuming it, because the visibility of a form depends on where the form is attached and which ACL groups can open that part of the chart.

What to confirm for this destination:

  • Who sees the data: Open the saved form as each role that should and should not see it, such as front desk, billing, a referring clinician and a covering provider. Record what each role can view.
  • Whether the field renders: Check that every field and group displays the stored value on the encounter, including after a page reload and in the printed or summary view.
  • Historical records: Edit the field's label, options or position in a test copy, then open an encounter saved before the change. Confirm whether old values still display with their original meaning.
  • Removed or renamed fields: Determine what happens to stored values when a field is deleted. Do not assume the data is preserved or hidden.
  • Audit trail: Confirm that edits to a saved form are logged with the user and time, and that the log meets your documentation policy.

Run these checks on a non-production copy with test patients before any form goes live.

Security controls for custom forms that hold patient data

A custom form is only as safe as the settings around it: who can change its definition, who can read what it captures, and what the patient portal shows back. The cards below map those settings to the OpenEMR security guidance and to the HIPAA Security Rule, which is a framework to map against, not a certification.

Who can edit form definitions

Layout Based Forms are defined through the admin interface, so anyone with permission to change a form can alter which fields collect data and how they display. Restrict form design to a small named group, separate that permission from clinical data entry, and keep a record of who changed each definition before a new version goes live. Map this to the access control and administrative safeguards in the HIPAA Security Rule.

Securing OpenEMR guide

Who can view saved entries

Form entries inherit the access rules of the encounter or patient chart they sit in, so a clinician-only assessment can be visible to front desk staff if the surrounding access is too broad. Test each custom form with a user from every role, including billing and front desk, and confirm that the answer does not change when the form is opened from a report. Document the expected result for each role so a later change can be tested against it.

What the patient portal exposes

If a form is marked for the portal, patients may see or complete fields that were meant for staff, such as internal risk notes or scoring. Review every portal-enabled field, decide whether the patient should read it back, and confirm the portal is served only over HTTPS with the admin scripts removed, as the Securing OpenEMR guide advises. Ask the portal owner to sign off on the field list before publishing.

Portal hardening steps

How uploads and attachments are stored

Forms that accept file uploads write those files to the document store, which is separate from the database fields. Confirm that the upload file white list is set to the types you need, that direct web access to the documents directory is blocked, and that the option to encrypt items stored on drive is evaluated for your environment. Check the storage path during testing, because a file that is blocked in the chart can still be reachable by its direct address.

Securing OpenEMR guide

Whether audit logs capture form activity

Auditors will ask who changed a form definition, who entered or edited data, and who viewed a saved entry. Verify that audit logging is turned on for both form changes and entry reads and writes, then run a test change and confirm it appears with user, time and record. Keep the log retention and review schedule in writing, and map the result to the audit control expected under the HIPAA technical safeguards.

Reviewing settings after staff changes

Form permissions drift as people move roles, leave the practice or receive temporary cover. Schedule a recurring review of who can edit definitions, who can see each form and which forms are published to the portal, and tie it to your joiner and leaver process. Keep the review output with the form change log so the same evidence answers both an internal review and an external assessment. The HIPAA Security Rule expects periodic evaluation of safeguards, so record the cadence you chose and why.

HIPAA Security Rule text

Keeping custom forms working through OpenEMR upgrades

A custom Layout Based Form is only as durable as the upgrade process around it, so the first decision is to treat every form as a maintained asset with an owner, a test record and a documented dependency list. Upgrades can break a form in three places: the form definition itself (its groups, field names and data types stored in the database), the mappings that other features rely on (report columns, portal display and any decision rule or export that reads a field by name), and the rendering of the form in a new PHP or OpenEMR release. None of these fail loudly in every case, so a form can look fine on the login screen and still lose data in a monthly report or a patient portal view. Start by writing an inventory that lists each custom form, the layout group and field names it uses, the encounter or patient data it writes, and every report, portal page, template or rule that reads from it. Keep the inventory in version control next to your OpenEMR configuration notes so it changes when the forms change.

Stand up a test instance that matches production in OpenEMR version, PHP version, database engine and the set of enabled features, and restore a recent copy of production data into it before each upgrade rehearsal. A test instance without real form data will not reveal problems in saved answers, and a test instance on a different database engine can hide differences in how data is stored. Confirm the upgrade path for the exact release your practice runs before you schedule anything, using the release notes and the upgrade guidance for that version; the project publishes its releases on OpenEMR releases on GitHub. Review the release notes for areas your forms touch, such as the encounter forms, the patient portal, billing and the fee sheet, since recent security releases in this line changed those areas. Then re-test every form in the inventory against a fixed script: create a new entry, edit a saved one, print or export it, check the report that reads it and confirm the portal view where it is used.

Keep a rollback plan that you have actually tested, not one that exists only on paper. Take a full database backup and a copy of the web root and the sites directory immediately before production upgrade, and verify that you can restore both to a separate host. Record which form definitions, reports and portal settings changed during the upgrade, so you can reverse only what broke. Decide in advance who has authority to roll back, how long the practice can run on the old version, and how entries made during the failed window will be recovered. Finally, confirm with your support provider or the OpenEMR community how custom layout changes are handled in the release you are moving to, because a form built on one version may need adjustment on another. Written scope for an upgrade and retest should state these steps, the forms covered and the acceptance criteria before work begins.

Questions buyers ask before building forms in-house or with a partner

What does a custom OpenEMR form project cost?

Cost depends on how many forms you need, how complex each one is, and how much clinical review and testing the work requires. The main cost components are the time spent defining fields, groups and report or portal use, the time spent building and reviewing each form, and the time spent testing with real clinical workflows. Some costs are one-time, such as the initial build, while others recur, such as changes after a clinical policy update or an OpenEMR upgrade. No public price list exists for this work. Ask any provider, including DeployOpen, for a written quote that lists each form, its fields, the environments included, the testing approach and the handover materials, so you can compare scopes rather than totals.

How long does it take to design and test a form?

Duration depends on how quickly your clinicians can agree on content, how many forms share logic or data, and how many review rounds your sign-off process requires. A simple intake form with standard fields usually moves faster than an assessment with scoring, conditional groups and report output. Testing takes longer than most teams expect because each form must be checked in the test environment, in reports and, if used, in the patient portal. Ask for a timeline with milestones for content approval, build, test and go-live, and confirm who is responsible for each sign-off.

What must the practice supply for a form project?

Three things determine whether the project moves on schedule: clinical content, sign-off and a test environment. Clinical content includes the questions, answer options, scoring rules and wording your clinicians use, along with any specialty standards the form must follow. Sign-off means named clinical and administrative owners who approve each form before it goes live. A test environment is a non-production OpenEMR instance that matches your production version and configuration, with test patient data that does not contain real protected health information. Confirm these inputs in the written scope so delays are visible early.

Can our own staff build simple forms in Layout Based Forms?

Often yes, for simple intake or contact-style forms that use standard field types and no scoring or cross-form logic. Staff who understand the clinical workflow, can follow a naming convention and can test changes in a non-production instance are well placed to start. The risk grows with complexity, shared fields used in reports or the portal, and any form that feeds billing or clinical decisions. Ownership matters here: someone must be accountable for each form, its version history and its review after each OpenEMR upgrade. Many practices split the work, with staff building simple forms and a partner handling complex ones and the upgrade checks.

How do custom forms survive OpenEMR upgrades?

Forms built with Layout Based Forms are configured in the application rather than written as core code, which lowers the chance that a core upgrade overwrites them. That is not a guarantee. Each release can change related database structures, reports, the portal or the rendering behavior your forms depend on. Before each upgrade, test every custom form in a copy of production, check the reports and portal views that use them, and keep an export or backup of the form definitions. Ask your provider how the upgrade test plan is written and whether it covers the release notes for each version you plan to move to. Confirm current upgrade requirements in the OpenEMR releases on GitHub before you schedule a change.

What ongoing work follows go-live?

Go-live starts a recurring workload. Clinical content changes when guidelines or payer rules change, and each change needs review, a version record and a test cycle. OpenEMR upgrades and security releases require regression checks on every custom form. Staff turnover means someone must still own each form and know where its definition and history are kept. Ask for a written plan that names who handles changes, how requests are prioritized, how upgrades are tested and whether ongoing support is a fixed retainer or billed per request. Support and retainer terms should be written into the scope before work begins.

What does a provider need to see before quoting a form project?

A provider needs your OpenEMR version, hosting model, list of target forms and the reports or portal screens that will display their data. Share a draft of each form, even a rough one, plus the names of the clinical and administrative owners who will approve it. Also state whether the forms touch protected health information in a test environment, because that determines how test data is prepared. A quote built on this information lists each deliverable, the assumptions behind it and the items you must supply, which makes it easier to compare providers on equal terms.

Limits to confirm before committing to Layout Based Forms

Layout Based Forms reduce custom code, but they have boundaries that depend on your OpenEMR version and how your practice works. The checks below are questions to answer with the vendor documentation or a test build before the form design is final.

Which field types and layouts exist

Confirm which field types, grouping options and layout controls your OpenEMR version offers for Layout Based Forms. Specialty intake often needs repeating groups, structured lists, or date and measurement fields, and a missing type can force a workaround. Build a sample of your most complex assessment in a test instance and record which elements you cannot represent.

OpenEMR releases

Limits on conditional logic and validation

Check whether fields can show or hide based on other answers, whether required-field rules can depend on another value, and how far validation can go before it becomes unmaintainable. Clinical intake often depends on age, diagnosis or consent answers, so test each branch you need and confirm how the form behaves when a branch is skipped.

How data appears in reports and the portal

Confirm whether form answers are stored in a form that reports can query, and whether the patient portal can display or collect the same fields. Reports built on custom form data can break when fields are renamed, so decide which fields need stable identifiers before data entry begins. Verify both views with a test patient.

Export and movement between instances

Ask whether a form definition can be exported from one instance and imported into another, such as from a test server to production or between sites. Also confirm whether stored answers travel with the definition. Without a tested export path, every environment may need manual rebuilds, which raises the cost of multi-site rollout.

Multilingual labels and translations

Confirm how form labels, option lists and help text are translated, and whether a translated label keeps the same stored value as the English one. Reports break when the same answer is stored under different text in each language. Test a second language with at least one list field before you commit to multilingual forms.

Workflows that need code

Decide early which parts of the specialty workflow a form cannot provide, such as calculations across encounters, external lookups, or actions triggered on save. Those needs usually move into a custom module, which has its own upgrade and testing cost. Document each gap so the team can estimate that work separately from the form build.

How DeployOpen scopes and delivers custom OpenEMR forms

DeployOpen plans, builds, documents and supports custom OpenEMR forms inside the practice's own infrastructure, including Layout Based Forms for specialty intake, assessment and encounter work. Each engagement starts from a written scope so the practice knows what is built, tested and handed over before work begins.

How we scope

  • Map each intake, assessment and encounter form to the workflow, roles and documentation it must support.
  • List the fields, groups, reports and portal views that will reuse each form, so their impact is agreed up front.
  • Agree deliverables and timelines in writing before work starts, since most engagements are fixed-scope.

How we build

  • Build Layout Based Forms in a non-production OpenEMR instance that matches your version, PHP and database setup.
  • Test each form for field behavior, data saved to the patient record, and access by the roles that will use it.
  • Record every form change so the build can be repeated on the next OpenEMR release.

How we hand over

  • Deliver a form inventory and build notes describing each field, group, dependency and report or portal link.
  • Walk your administrators through the form settings and the steps to update them after an upgrade.
  • Provide a test checklist your team can rerun before each OpenEMR upgrade, so custom forms are verified each time.

How we support

  • Review custom forms against each OpenEMR release that your team plans to adopt before it goes live.
  • Offer ongoing support, upgrades and continuous testing as a retainer if your team wants DeployOpen to keep forms current.
  • Ask any partner for a quote built from the written scope, and confirm which support terms apply to your environment.

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.