Ripple Effect Cursor - MeggiTools
Run
Toggle Theme
Share Link
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Ripple Effect Cursor</title> <style> body { margin: 0; overflow: hidden; background: #000; } .ripple { position: absolute; border-radius: 50%; background: rgba(255, 255, 255, 0.5); pointer-events: none; animation: ripple 1s linear infinite; } @keyframes ripple { from { transform: scale(0); opacity: 1; } to { transform: scale(5); opacity: 0; } } </style> </head> <body> <script> document.addEventListener('mousemove', function(e) { const ripple = document.createElement('div'); ripple.className = 'ripple'; ripple.style.width = ripple.style.height = `${Math.random() * 20 + 10}px`; ripple.style.left = `${e.pageX - ripple.offsetWidth / 2}px`; ripple.style.top = `${e.pageY - ripple.offsetHeight / 2}px`; document.body.appendChild(ripple); setTimeout(() => ripple.remove(), 1000); }); </script> </body> </html>