Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

Close a firefox tab programmatically

more options

I'm a web developer and I want to close a firefox tab programmatically with javascript...normally window.close(); should do the trick however with new versions of firefox the code just don't work and I searched a lot among forums and I couldn't find the proper answer...since this is the official site of mozilla firefox I taught maybe I could find an answer here... So how can I close a firefox tab programmatically? thanks

I'm a web developer and I want to close a firefox tab programmatically with javascript...normally window.close(); should do the trick however with new versions of firefox the code just don't work and I searched a lot among forums and I couldn't find the proper answer...since this is the official site of mozilla firefox I taught maybe I could find an answer here... So how can I close a firefox tab programmatically? thanks

All Replies (1)

more options

If your code is opening that window, you should be able to close it via window.close(); If it is a window that you didn't open it isn't going to work.