Menu
×
   ❮     
HTML CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C C++ C# BOOTSTRAP REACT MYSQL JQUERY EXCEL XML DJANGO NUMPY PANDAS NODEJS R TYPESCRIPT ANGULAR GIT POSTGRESQL MONGODB ASP AI GO KOTLIN SASS VUE DSA GEN AI SCIPY CYBERSECURITY DATA SCIENCE
     ❯   

HTML onmousemove Attribute


Definition and Usage

The onmousemove attribute fires when the pointer is moving while it is over an element.


Applies to

The onmousemove attribute is part of the Event Attributes, and can be used on any HTML elements.

Elements Event
All HTML elements onmousemove

Example

Img Example

Execute a JavaScript when moving the mouse pointer over an image:

<img onmousemove="bigImg(this)" src="smiley.gif" alt="Smiley">
Try it Yourself »

Browser Support

Event Attribute
onmousemove Yes Yes Yes Yes Yes