How do I embed custom code in my Wix website?
How to Embed Code in Wix
Embedding custom code in your Wix website allows you to add HTML, JavaScript, or third-party widgets to enhance functionality and design. The process varies slightly depending on whether you're using the Wix Editor or Wix Studio.
Using the Wix Editor
- Open the Wix Editor and navigate to the page where you want to add code
- Click the Add (+) button on the left sidebar
- Select Embed and choose HTML iframe (or "Embed a Site" for external website URLs)
- Drag and resize the gray box that appears on your page
- Click Enter Code
- Choose Code and paste your HTML or JavaScript code
- Click Update to embed the code onto your page
For adding custom JavaScript files, you'll need to enable Dev Mode from the top menu to manage custom JS files directly in your site code.
Using Wix Studio
- Open your website in the Wix Studio editor
- Click the Add Elements (+) button in the top-left corner
- Select Embed & Social
- Click Embed Code
- Click the + symbol next to Embed Code to add your custom HTML/JavaScript
- Paste your code in the popup box
- The code will render on your page automatically
What You Can Embed
This method works for various types of content including:
- Custom HTML and CSS
- JavaScript widgets and interactive elements
- Third-party forms (like Jotform or Google Forms)
- Social media feeds
- Video players from platforms like YouTube
- External website iframes
- Analytics tracking codes
Important Tips
Resize the embed container to fit your content properly after adding the code. Both platforms support HTML, JavaScript, iframe embeds, and external URLs, giving you flexibility to customize your site beyond Wix's built-in features.
For more advanced customization options, visit Wix's official support documentation.