var iframe = document.getElementById('myIFrame'); iframe.contentWindow.body.addEventListener('mouseup', Handler); function Handler() { alert('works'); }