Embed Code Setup
Add Odyn embed codes to your website to load deployed scripts and styles.
Embed codes load your deployed JavaScript and CSS from the Odyn CDN. After deploying, copy the embed snippet from the deployment panel and paste it into your site.
Where to Place Embed Codes
Place <script> tags before the closing </body> tag. Place <link> stylesheet tags in the <head>.
If you use external dependencies, their tags appear first in the embed snippet. Load order matters — dependencies execute before your project code.
Webflow Setup
- Open your Webflow project settings.
- Navigate to Custom Code.
- Paste the embed code in the Footer Code section (for scripts) or Head Code section (for stylesheets).
- Publish your Webflow site.
Odyn auto-detects webflow.io staging domains when generating embed snippets. If your staging site lives somewhere else, add it under Staging Domains so the auto-detect embed serves it the staging build.
Embed Code Modes
Odyn generates different embed snippets depending on your deployment mode:
- Bundled — A single
<script>tag for the IIFE bundle. - Per-file — Individual
<script type="module">tags per entry point. - Folder bundle — Separate
<script>tags per folder bundle.
See the Embed Code Reference for exact snippet formats.
Verification
After embedding, open your browser's developer tools and check:
- The Network tab shows successful 200 responses for your CDN URLs.
- The Console tab shows no loading errors.
- Your code executes as expected on the page.