Window opener property
Window Object
Definition and Usage
The opener property is a readable and writable property that returns a reference to the Window object that created this window.
When you open a window with window.open(), you can use this property to return details about the source (parent) window of the target window.
Code hint: window.opener.close() will close the source (parent) window.
Syntax
window.opener
Browser support





All major browsers support the opener property
Example
Example
Write text to the opener window (parent window):
Try it »
Window Object