How to disable image drag on a webpage?

Hi there,

I’m having an issue with people dragging my image on my website. See screenshot attached. Is there a way to disable this on webflow?

the construction on webflow that I put on for this image is:

You can use pointer-events to prevent users from clicking/selecting a specific element, but you’ll need to use custom code as this control isn’t available natively in the Designer.

Place the code below in either the page or project custom code section (before the </head> tag)— just be sure to update the YOUR-CLASS text with the class name of the element in question:

<style>
.YOUR-CLASS { pointer-events: none; }
</style>

If you get stuck, reply with your read-only link (or a link to the live site) and I’d be happy to take a closer look :+1: