Streaming live at 10am (PST)

Integrating codepen javascript

Hey guys, I’m not new to webflow, but I am new to playing with custom code.

Anyway, I’m trying to integrate this codepen: into my project as a background to the hero section.
Here’s my webflow page:

I found someone on the forum explaining how to integrate particles.js, but I am not sure this would work the same way?

Hi @Gaitanov

I’m not sure you can integrate this script the same way you would integrate Particles.js.

Go into the webflow designer and add an embed widget where you want your animation to appear.

In your embed, add the following libraries before your script:

<script src=""></script>
<script src=""></script>
<script src=""></script>
<script src=""></script>

You can then add your codepen script just below these librairies, inside script tags (still inside your embed).

Sometimes there’s an issue with some blank space at the bottom of the canvas. To avoid this issue, you can go into your site settings > custom code > And in the “head” code add the following:

canvas {
    display: block;

Let me know if this works.



Hey @Blaise_Posmyouck
Yeah this worked like a charm. Thanks!!!
Only issue now is that the canvas positions itself weirdly in the middle of my page, for some reason.

I tried the same, it appears blank every time.
Please Help!