On this page
What this issue is
Autofill is the browser feature that fills in your name, email, phone or address from saved details. When it fills a field, Chrome and Safari add the :-webkit-autofill state to the input and paint it with a default background (often light blue or pale yellow).
The problem appears when your form uses light text, or a dark theme, or a transparent field on a coloured section. The browser overrides the background but your text colour stays. Result: white text on a pale yellow field, or text that looks faded and cannot be read. Some themes also show a mismatched fill that clashes with the design.
Why it costs you leads or sales
Autofill is meant to speed up forms. If the filled values are unreadable, people cannot check them. Some will clear the field and retype, some will submit a typo they could not see, and some will leave. The impact is usually small and limited to certain browsers and themes, but it hits the visitors who were fastest to convert.
- Open formPage loads normally
- Autofill fills fieldsBrowser adds pale background
- Read the valuesLight text on pale fill
- Submit formVisitor hesitates or leaves
- Lead arrivesNever happens
The form works technically, but the visitor cannot read what was filled in.
The form loads, autofill applies, and the filled text cannot be read.
How to check if your site has it
Save test details in the browser
In Chrome, open Settings > Autofill and passwords > Addresses and more, and add a test address, phone and email. In Safari, add a contact card and enable Settings > AutoFill.
Open the form in a normal window
Click into the first field and pick the suggestion. Check every filled field for contrast and colour mismatch.
Repeat on dark sections and dark mode
Test any form on a dark background, and test with your operating system in dark mode, because that is where the problem is most common.
Test both browsers and mobile
Try Chrome on desktop, Safari on macOS and Safari on iPhone. Their autofill colours differ.
Inspect the field
In DevTools, right-click the filled input and choose Inspect. In the Styles pane, look for a user agent rule on
input:-webkit-autofillthat sets the background.
How to fix it
Browsers do not let you simply set background-color on an autofilled field. The usual fix is to cover the fill with a large inset box-shadow in your colour, and set the text colour with -webkit-text-fill-color.
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
textarea:-webkit-autofill,
select:-webkit-autofill {
-webkit-text-fill-color: #111111;
caret-color: #111111;
-webkit-box-shadow: 0 0 0 1000px #ffffff inset;
box-shadow: 0 0 0 1000px #ffffff inset;
transition: background-color 5000s ease-in-out 0s;
}Open the Customizer
Go to Appearance > Customize > Additional CSS (classic themes). With block themes, use Appearance > Editor > Styles > Additional CSS.
Paste the snippet
Paste the CSS and publish. If your form plugin sets its own colours, target its field class too.
Edit theme code
Go to Online Store > Themes > Edit code and open your main stylesheet in Assets (for example base.css).
Add the snippet
Paste the CSS at the end and save. Adjust colours to match your theme settings.
Add custom code
Go to Site settings > Custom code > Head code and wrap the CSS in a style tag, or use an Embed element on the page.
Publish
Publish the site and test on the live domain.
Add custom CSS
In the funnel or website builder, open Settings > Custom CSS (or the page's custom code section) and paste the snippet.
Preview and test
Use the form field class names shown in the builder if the default selectors do not take effect.
Check what is possible
Wix forms have limited CSS access. If you use Wix Studio, add the CSS through Custom code or a site-level stylesheet where available.
Fall back to field colours
If you cannot add CSS, choose field colours that stay readable on a pale fill, such as dark text on a light background.
Open Custom CSS
Go to Website > Website Tools > Custom CSS.
Paste and save
Paste the snippet, set your colours and save.
Add to your stylesheet
Put the rule in your global CSS after your input styles so it wins on order.
Keep it scoped if needed
Prefix with a form class, such as .signup-form input:-webkit-autofill, if different forms use different colours.
Before
- Browser paints a pale fill
- Your light text colour stays
- Values are hard to read
- Visitors retype or leave
After
- Field keeps your own colours
- Text colour is set explicitly
- Values are clearly readable
- Visitors check and submit
How to confirm it's fixed
- Autofill each field type in Chrome on desktop and read every value.
- Repeat in Safari on macOS and on an iPhone.
- Test with the system in light mode and dark mode.
- Test the form on any dark or coloured section.
- Check focus and hover states still look right.
- Submit a test lead and confirm the values arrive correctly.
How to prevent it happening again
Put the autofill rule in your shared form styles, not on a single page, so new forms inherit it. When you change brand colours or add a dark theme, update the colours in the rule. Add autofill to your pre-launch checklist for any new form or redesign.
How FunnelGuard handles this
FunnelGuard does not check for this yet. Autofill styling is a visual detail that depends on the browser's saved data, so it is only a possible future check.
What FunnelGuard does cover nearby: a robot visitor runs your real journeys on a schedule, completes the lead form, checks each step and the tracking hits, and confirms test leads reach the inbox and CRM. If a form breaks outright, you get one alert with a screenshot and a likely cause. It will not tell you that autofilled text looks unreadable.
To watch for it yourself, re-run the autofill test above after every theme, plugin or brand colour change, and keep a saved test profile in Chrome and Safari. You can also use browser DevTools to emulate dark mode and review each form.
Questions people ask
Why is my autofilled text white or invisible in Chrome?
Chrome paints autofilled fields with its own pale background but may keep your text colour. If your text is light, it ends up pale on pale. Set -webkit-text-fill-color and an inset box-shadow on input:-webkit-autofill to fix it.
How do I change the autofill background colour in Chrome?
You cannot set background-color directly because the browser overrides it. Use a large inset shadow instead, for example box-shadow: 0 0 0 1000px #fff inset, on the :-webkit-autofill state.
Why do my form fields turn yellow or blue after autofill?
That is the browser's default autofill highlight. Chrome and Safari add it to show a field was filled automatically. You can override it with CSS using the :-webkit-autofill selector.
Does autofill styling affect Firefox?
Firefox uses the :autofill pseudo-class and usually handles colours differently. The :-webkit-autofill fix targets Chrome, Safari and other WebKit or Blink browsers, so test Firefox separately.
Should I turn autocomplete off to avoid autofill styling problems?
No. Turning autocomplete off removes a feature visitors like and browsers often ignore it. Fix the styling instead and keep proper autocomplete values like email and tel.
Why does autofill look wrong only in dark mode?
Dark themes usually use light text, and the browser's pale autofill fill clashes with it. Set both the text colour and the inset shadow colour in your autofill rule to match your dark field style.
Does FunnelGuard detect autofill styling problems?
No. FunnelGuard does not check this yet. It does monitor your real form journeys, tracking and lead delivery, so you still need a manual autofill test after design changes.
Related issues
- PRF-201Dark mode (prefers-color-scheme) makes text invisibleFix guide
- PRF-191Page broken in Safari (iOS/macOS)Fix guide
- PRF-202Forced dark mode in Android Chrome inverts logos/images badlyFix guide
- PRF-205High-DPI/zoom 200% breaks layoutFix guide
- PRF-192Page broken in FirefoxFix guide
- PRF-193Page broken in Samsung InternetFix guide