Your entire Webflow page styling may change on publish—especially the navbar—after adding the Uploadcare widget because the widget's script is likely injecting global styles or conflicting with existing class names or CSS rules.
1. Understand What Uploadcare Injects
- The Uploadcare widget uses external JavaScript and CSS that loads when the site is published.
- It may apply global styles (e.g., affecting font sizes, margins, button styles) or use HTML elements or class names that conflict with your Webflow site's styles.
- These changes won’t appear in Designer or Preview mode, only in the published site where the Uploadcare scripts run.
2. Identify Conflicting Styles
- Open the published version of your site in Chrome.
- Use DevTools (Inspect Element) to examine the changed elements (like the Navbar).
- Check for:
- Unexpected CSS overrides coming from Uploadcare.
- Generic class names (e.g.,
.button
, .navbar
) in Uploadcare’s styles that may clash with your site. - Any global tag selectors being overridden (like styling all
<form>
, <input>
, <button>
, etc.).
- Wrap the Uploadcare script or widget in a div with a unique class (e.g.,
.uploadcare-wrapper
) to help scope any custom styling. - You can also try adding Custom Code that defers or scopes the widget’s appearance.
4. Use Custom CSS to Override Unwanted Changes
- In Webflow, go to Page Settings > Custom Code or Site Settings > Custom Code.
- Add custom styles inside the
<style>
tag to explicitly redefine important styles affected by Uploadcare. - Example: Reinforce your Navbar’s default styles (
.w-nav { background-color: #fff !important; }
). - Use !important judiciously to override injected styles.
5. Check for JS Conflicts
- Uploadcare’s script may attach behaviors to forms or buttons. Make sure it doesn’t interfere with Webflow’s built-in form handlers.
- If necessary, load Uploadcare only on specific pages using conditional script loading.
Summary
When you add the Uploadcare widget, it injects external styles and scripts that can override Webflow’s CSS, especially after publishing. Use browser inspection, scoped containers, and custom styles to isolate or override those conflicts and restore your page’s intended design.