contact@itechcloudsolution.com +91 997 9933 595 +91 972 6015 295
209-210-211, Western Plaza, Simada Naka, Surat, Gujarat, India 395006.
iTechCloud Solution
Book a call→
News & Insights

How to Set Up Dynamic Forms in Salesforce Lightning

Dynamic Forms in Salesforce Lightning revolutionise how admins customise pages by allowing them to control field and section visibility dynamically. Traditionally, page layouts have been the primary method for displaying fields on record pages, but they often lack flexibility, leading to multiple page layouts for different profiles or record types. Dynamic forms improve this by allowing admins to configure fields and sections dynamically, giving them better control and enhancing the user experience.

Subhash Panchani headshot
Subhash Panchani
Founder & CEO · iTechCloud Solution
·4 min read
How to Set Up Dynamic Forms in Salesforce Lightning cover image

Table of Contents

What Are Dynamic Forms?

Why Do You Need Dynamic Forms?Set Up Dynamic Forms in Salesforce Lightning

Step 1: Enable Dynamic Forms in Salesforce

Step 2: Create or Edit a Lightning Record Page

Step 3: Add Fields Using Dynamic Forms

Step 4: Configure Field Visibility and Component Behavior

Step 5: Organize Field Sections

Step 6: Test and Activate Dynamic FormsConclusion: Dynamic Forms in Salesforce

What Are Dynamic Forms?

Dynamic Forms allow Salesforce admins to:

Place Fields Anywhere: Fields can be dragged and dropped anywhere on a Lightning page, not just within the Details section.

Control Visibility Dynamically: Show or hide fields and sections based on criteria like field values, user profiles, or record types.

Reduce Page Layout Dependency: Avoid creating multiple page layouts by managing field visibility with conditional logic.

Why Do You Need Dynamic Forms?

Improved Page Performance: By displaying only the necessary fields, dynamic forms reduce page load time and enhance efficiency.

Customized User Experience: Users see only the fields relevant to their role, simplifying their interface.

Eliminates Excessive Page Layouts: No need to create multiple layouts to cater to different profiles or scenarios.

Easy Maintenance: Page updates become quicker since all modifications can be managed from a single Lightning record page.

Set Up Dynamic Forms in Salesforce Lightning

Step 1: Enable Dynamic Forms in Salesforce

Go to Setup:Click on the gear icon in the top-right corner.

Select Setup from the dropdown.

Search for ‘Record Page Settings’:Use the Quick Search search box to look for Record Page Settings.

Enable Dynamic Forms:Scroll down to the Dynamic Forms section.

Toggle the switch to enable dynamic forms for your organization.

Step 2: Create or Edit a Lightning Record Page

Navigate to Object Manager:In Setup, go to Object Manager.

Select the object where you want to create or modify a record page.

Click on Lightning Record Pages:Under the selected object, locate Lightning Record Pages.

Click on New to create a new Lightning Record Page or select an existing one to edit.

Choose a template:Select a page template that best fits your design goals.

Click Finish to proceed to the Lightning App Builder.

Step 3: Add Fields Using Dynamic Forms

Open Lightning App Builder:In the Lightning App Builder, locate the Field Section component.

Drag and drop the field section onto the desired area of the page.

Add Individual Fields:After placing the Field Section, click on it.

Drag individual fields from the Fields Panel into the section.

Configure Field Properties:Click on any field to configure its properties.

Use the Set Component Visibility feature to define visibility rules.

Step 4: Configure Field Visibility and Component Behavior

Set Component Visibility:Click on the field or section to open the properties panel.

Under Set Component Visibility, define criteria using:Field Values: Show/hide fields based on record data.

User Profiles: Tailor visibility to different profiles.

Advanced Criteria: Combine multiple conditions using AND/OR logic.

Define Visibility Rules:Use simple or advanced logic to configure conditions.

For example, show a “Discount Reason” field only when the Discount field value is greater than 20%.

Set Field-Level Security:Ensure that sensitive fields are only visible to authorized profiles by setting field-level security appropriately.

Step 5: Organize Field Sections

Group Related Fields:Use multiple field sections to group fields based on their purpose.

For example, place contact information fields in one section and account-related fields in another.

Use collapsible sections:Enable collapsible sections to improve page efficiency.

Users can expand or collapse sections as needed.

Reorder Sections:Drag and drop field sections to reorder them for optimal user experience.

Step 6: Test and Activate Dynamic Forms

Preview the page:Click on Preview to assess how the page looks with different profiles and conditions.

Verify that visibility rules and conditional logic work as expected.

Save and Activate:Once satisfied, click Save.

Click Activate to assign the page asOrg Default: Default for all users.

App Default: For specific Lightning apps.

Profile or Record Type Specific: Tailored based on user profiles or record types.

Dynamic Forms in Salesforce Lightning provide a flexible, user-centric way to customise record pages by allowing admins to control field and section visibility dynamically. By eliminating the need for multiple page layouts, Dynamic Forms enhance page performance, reduce complexity, and offer a personalized user experience. With the ability to define field-level visibility based on criteria such as profiles or field values, admins can efficiently manage record pages.

Key takeaways
Subhash Panchani headshot
Written by
Subhash Panchani
Founder & CEO · iTechCloud Solution

Founder and CEO of iTechCloud Solution, a Salesforce consulting and product partner since 2017. He sets engagement strategy and stays the commercial owner of every account, working with clients across Salesforce, AI and data from the first call through to go-live.

Connect on LinkedIn
Put it to work

Want this applied to your org?

Book a free discovery call and we'll map the highest-ROI next step for your team.

Book a call →

Related insights

All articles →
15 Common Implementation Mistakes That Cost Companies Time & Money
News & Insights
Jun 30, 2026 · 15 min read

15 Common Implementation Mistakes That Cost Companies Time & Money

Read article →
8 Ways to Ensure Salesforce Adoption Rate Stays Above 80%
News & Insights
Jun 30, 2026 · 8 min read

8 Ways to Ensure Salesforce Adoption Rate Stays Above 80%

Read article →
The 5 Biggest Salesforce Risks You Can't Ignore in 2026
News & Insights
Jun 29, 2026 · 4 min read

The 5 Biggest Salesforce Risks You Can't Ignore in 2026

Read article →

Have a similar problem?

Send us the shape of it. We will tell you honestly whether we are the right team.

  • Response within one business day
  • Salesforce-certified architects on the call
  • Delivery across US, UK, EU, Middle East and APAC