> For the complete documentation index, see [llms.txt](https://codifi-fdm.gitbook.io/codifi-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://codifi-fdm.gitbook.io/codifi-docs/cross-platform-features/conditional-visibility.md).

# Conditional Visibility

**Available on:** Web and Mobile

Conditional Visibility lets administrators define rules that control when sections and fields appear in a Record. Rules are set up in the Library and automatically propagate to Projects and mobile devices.

> Conditional Visibility is powered by [Ripple](/codifi-docs/cross-platform-features/ripple.md). For deeper coverage of visibility patterns and formula authoring, see [Visibility Formulas](/codifi-docs/cross-platform-features/ripple/visibility-formulas.md).

> **Screenshot placeholder:** *Library view showing an Archetype with a visibility condition configured on a section.*

## What Is Conditional Visibility?

Visibility rules determine whether a section or field is shown or hidden based on the current value of another field. For example:

* Show the **Soil Contamination** section only when **Contamination Detected** is set to **Yes**
* Hide the **Repair Details** field unless **Damage Present** equals **Yes**
* Display an additional notes field when a dropdown value contains a specific keyword

Hidden fields **retain their data** — hiding a field does not delete any values already entered. If the field becomes visible again later, the previous value reappears.

***

## Configuring (Web)

Visibility rules are configured in the **Library** on the web app. You must have administrator access to edit archetypes.

1. Open the **Library** and navigate to the Composition you want to edit.
2. Select the **Archetype** that contains the section or field you want to control.
3. Click the section or field to open its settings.
4. Under **Visibility**, add a new condition.
5. Configure the condition:
   * **Source field** — the field whose value will trigger the rule.
   * **Operator** — `equals`, `not equals`, `contains`, `is empty`, `is not empty`, etc.
   * **Value** — the value to compare against.
6. Add additional conditions if needed. Multiple conditions can be combined with AND/OR logic.
7. **Save** the Archetype. Rules propagate automatically to all Projects using this Composition and to connected mobile devices.

> **Screenshot placeholder:** *Condition builder panel showing source field, operator, and value selectors.*

### Runtime behavior on web

Sections and fields appear or disappear dynamically as users fill in a Record. No save or page refresh is required — visibility updates instantly as values change.

***

## Using in the Field (Mobile)

The same visibility behavior is replicated offline-first on mobile using the **Ripple formula engine**. Rules evaluate locally on the device, so they work even without an internet connection.

Field crews experience visibility as the form **adapting in real time** — sections expand to show new fields when a triggering value is entered, and collapse to hide irrelevant fields when a value changes back.

Because hidden fields retain their data, crews can experiment without fear of losing entered values: changing a triggering field hides the dependent section but preserves its contents.

***

## Use Cases

* Show specialized assessment sections only when a qualifying condition is detected (e.g., **Damage Assessment** fields when **Damage Present** = Yes).
* Simplify long forms by hiding fields that are not relevant to the current Record.
* Build branching forms that adapt based on the type of observation being entered.
* Reduce data entry errors by surfacing only the fields that apply to the current situation.

## Tips

* Use a field's **ID** (not its display label) when referencing it in conditions, to avoid issues if the label is later renamed.
* Test visibility rules in a sample Project before rolling them out to active field Projects.
* Changes to Library visibility rules propagate to existing Projects automatically — you do not need to recreate Projects.
* Visibility rules apply at both the **section** and **field** level. A hidden section hides all fields within it.
