On this page
What this issue is
Layout shift is when visible content moves without the visitor asking for it. On forms, a common cause is validation: a visitor leaves a field blank or types a bad email, and a red message appears. If that message is added to the page flow, every field below it jumps down by the height of the message.
The shift is worst when the message appears above the field, or at the top of the form as a summary. The field the person is about to tap moves out from under their finger. Messages that wrap onto two lines on a narrow phone make the jump bigger.
- Visitor fills the formMoves from field to field
- Field loses focusValidation runs on blur
- Error inserted aboveNext field moves down
- Tap lands on wrong spotMis-tap or lost place
- Form abandonedNo lead captured
The error is inserted in the page flow, so everything below it moves.
Why it costs you leads or sales
Forms are where visitors turn into leads or buyers. Anything that makes the form feel unstable adds friction at the last step. People tap the wrong field, hit a link or button that moved into place, or simply lose track of what to fix.
It also counts as layout shift in Google's Cumulative Layout Shift (CLS) metric when the shift is not within 500 ms of a user input. Validation that runs on blur or after a server response can fall outside that window, so it may add to your CLS score. Impact is usually medium: it rarely blocks a form outright, but it hurts mobile completion most.
Example: illustrative numbers only, not measured data. Stable error placement keeps more visitors moving through the form.
How to check if your site has it
Trigger every error
Open the form on a phone-sized screen. Leave required fields empty, type an invalid email and phone number, then tap submit.
Watch the fields below
Note whether any field, label or the submit button moves when a message appears. Try both blur validation and submit validation.
Record the shifts in Chrome DevTools
Open DevTools, go to the Performance panel, record while you trigger errors, then look for red Layout Shift entries in the Experience row. Select one to see which element moved.
Highlight shifts live
In DevTools open the Rendering tab and tick Layout Shift Regions. Shifted areas flash blue as you trigger errors.
Try long messages and narrow screens
Test a 320 px wide viewport and any translated versions of the page. Longer text wraps and makes the shift larger.
How to fix it
There are two reliable approaches. Reserve space: give every field a message area with a fixed minimum height, so showing text fills space that was already there. Place it out of flow: show the message below the field in a reserved slot, or in a tooltip or overlay that does not push content. Avoid inserting messages above the field.
Before
- Error injected above the field in normal flow
- Fields and button jump down on every error
- Summary banner at the top of the form pushes everything
After
- Each field has a message slot with reserved height
- Error text fills the slot, nothing moves
- Summary uses a reserved area or sits next to the button
.field { margin-bottom: 0; }
.field-error {
min-height: 1.5em; /* room for one line, always present */
font-size: 0.875rem;
line-height: 1.5;
color: #b00020;
}
/* Empty message keeps its height, visible text fills it */
.field-error:empty { visibility: hidden; }<label for="email">Email</label>
<input id="email" type="email" aria-describedby="email-error">
<div id="email-error" class="field-error" aria-live="polite"></div>Find your form plugin's error styles
Plugins such as Contact Form 7, WPForms, Gravity Forms and Elementor Forms each use their own error classes. Inspect an error in the browser to find the class name.
Add CSS under Appearance > Customize > Additional CSS
Give the field wrapper or error class a min-height, or position the message so it does not add to the flow. Test with the plugin's own validation settings.
Prefer messages below fields
If your plugin offers an error position or summary option, choose the one that does not insert content above the fields.
Edit your theme code
Go to Online Store > Themes > Edit code. Errors on login, contact and customer forms are rendered in the form template and styled in the theme CSS.
Add a reserved error area
Add a min-height rule to the error element for each field in your theme's CSS file. Theme structure varies, so check the template your theme uses.
Check app forms separately
Forms added by apps are styled by the app. Look for its custom CSS setting.
Style the error message element
In the Designer, select the form block's Error Message element (shown by switching the form to its error state) and set a fixed height.
Keep it below the fields
Place the error message after the fields or button area. Preview with the state toggled on to check nothing moves.
Open the form or survey builder
Add Custom CSS in the form's settings or at funnel page level.
Reserve space for messages
Inspect an error in the live page for its class name, then add a min-height rule for it.
Use Wix form settings
Wix Forms controls its own error text. Check the form's design settings and leave enough spacing between fields to absorb the message.
Test in preview on mobile
Switch the editor to mobile view and trigger errors. If fields still jump, use more spacing or fewer long messages, as custom CSS control is limited.
Open Design > Custom CSS
Squarespace form blocks show errors under fields. Inspect the error element to find its class.
Add a min-height
Reserve space for the message with CSS, then test on a phone.
Render a message slot per field
Keep an element for each error in the HTML at all times and fill it with text instead of creating and removing it.
Use a fixed min-height
Use the CSS above. Keep text short so it rarely wraps.
Keep the submit button stable
Do not place a top-of-form error summary in flow. Reserve space for it or show the message beside the button.
How to confirm it's fixed
- Triggering every error moves no field, label or button
- Layout Shift Regions shows no flashes when errors appear
- The Performance panel records no layout shift entries during validation
- Long messages on a 320 px screen still do not move the form
- Screen reader still announces each error
- The form still submits with valid data
How to prevent it happening again
Add error-state testing to your release checklist for any form change, theme update or new plugin. Agree one error pattern in your design system and reuse it. Keep copy short, and recheck after translating the page, because longer text wraps.
You can also monitor real-user CLS in the Core Web Vitals report in Google Search Console, or with the Chrome User Experience Report, and run Lighthouse or PageSpeed Insights after form changes. Lab tools often miss validation shifts because they do not trigger errors, so manual tests remain necessary.
How FunnelGuard handles this
FunnelGuard does not check for this yet. Detecting layout movement while validation messages appear is a possible future check, not a current feature.
What FunnelGuard does do nearby: a robot visitor runs your real lead form journey on a schedule from the EU or the US, checks each step, and confirms the test lead reaches the inbox and CRM. If a form stops working, a failure is re-checked from a second region and you get one alert with a screenshot and a likely cause. That tells you whether the form submits, not whether the layout moves.
To watch for layout shift on forms, use the manual checks above, Lighthouse or PageSpeed Insights, and the Core Web Vitals report in Search Console. A free read-only website audit and a free plan (1 site, 2 journeys, daily checks, no card) are available if you want to monitor form submissions alongside.
Questions people ask
Why do my form fields jump when an error message appears?
The error message is being added to the page flow, usually above or between fields, so everything below it is pushed down. Reserve a fixed-height slot for each message so the text fills space that already exists.
How do I stop form validation messages from causing layout shift?
Keep an empty message element under each field with a min-height of about one line, and fill it with text when validation fails. You can also show errors in an overlay or tooltip that does not take up space in the layout.
Does form validation affect Cumulative Layout Shift (CLS)?
Yes, it can. Layout shifts that happen more than 500 ms after a user input are counted, so validation on blur or after a server response may add to your CLS score. Shifts right after a tap or key press are usually excluded.
Should error messages go above or below form fields?
Below the field is the safer choice, in a space that is reserved in advance. Messages above a field move the field the person is about to use, which causes mis-taps, especially on phones.
How can I see which element shifted when an error appears?
In Chrome DevTools, open the Rendering tab and tick Layout Shift Regions, then trigger the error. You can also record in the Performance panel and select the Layout Shift entry to see the moved elements.
Will reserving space for errors hurt accessibility?
No, as long as the message stays in the page text. Link it to the input with aria-describedby and use aria-live="polite" so screen readers announce it.
Does FunnelGuard detect layout shift from form validation?
No, not yet. FunnelGuard checks that your form journey works and that test leads arrive, but layout shift on validation is only a possible future check. Use DevTools, Lighthouse and Search Console to watch for it.
Related issues
- PRF-025CLS over 0.1 on a funnel stepFix guide
- PRF-026Cookie banner pushes content down, CLS 0.3Fix guide
- PRF-038CTA moves just as user taps it (mis-click onto other element)Fix guide
- PRF-031Images without dimensions shift text below themFix guide
- PRF-034Late-loading price or stock widget shifts Add to cart buttonFix guide
- PRF-035Sticky header changes height on scroll causing jumpsFix guide