How to make an Icon Spin

I used the following code in webflow, the icon will NOT spin.
img class=“image-to-spin” src=“https://cdn.prod.website-files.com/668422158b0b1544bb543b1f/66ad457f06ccedc505370dfc_10.png” alt=“icon” height=“200” width=“200” (I removed the <> to show the coding)

I try elsewhere the icon will spin. https://codepen.io/limxz/pen/GLZdJN.

Please help, I want this icon to spin in my webflow website. Thanks Mass!


Here is my site Read-Only: LINK
(how to share your site Read-Only link)

You’ve shown the image, but you need the CSS as well in order to set this up using the CSS animation you’ve shown.

Otherwise you’ll want to look into Webflow Interactions which are built into the designer.

where do I put the CSS code in webflow, with the HTML code?

You can do that with code

Anywhere you want, put it in an Embed element if you like.
Note you can’t do custom code on the free site + free workspace plans.

You should learn interactions.