How can I import my HTML and CSS custom code into Webflow?

TL;DR
  • Add HTML by dragging an "Embed" element into your Webflow project and pasting your code.
  • Include CSS by adding code under the "Custom Code" tab in the project's Head Code section.
  • Test the integration by previewing the page and checking for conflicts.

To import your HTML and CSS custom code into Webflow, you'll need to follow certain steps to integrate them properly while leveraging Webflow's design features.

1. Add HTML Embed Elements

  • Open your Webflow project and navigate to the page where you want to add your custom HTML.
  • Drag an "Embed" element from the Add panel onto the Canvas.
  • Paste your custom HTML code into the Embed Code Editor and click "Save & Close."

2. Include Custom CSS

  • Go to Project Settings from the Dashboard.
  • Select the "Custom Code" tab.
  • In the Head Code section, add your CSS between <style> tags.
  • Remember that CSS in the Embed Code may not appear in the Designer mode but will show in Preview and Publish modes.

3. Test Your Custom Code

  • Preview the page to ensure that your HTML and CSS are functioning as expected.
  • Check for any styling conflicts between your custom CSS and Webflow's generated CSS.

Summary

To use custom HTML and CSS in Webflow, utilize the "Embed" element for HTML and the "Custom Code" settings for CSS. This ensures your code integrates smoothly with Webflow's functions and styling.

Rate this answer

Other Webflow Questions