Access window variable from Content Script [duplicate]
This question already has an answer here: Chrome extension - retrieving global variable from webpage 5 answers Hijacking a variable with a userscript for Chrome 1 answer I have a Chrome Extension that is trying to find on every browsed URL (and every iframe of every browser URL) if a variable window.my_variable_name exists. So I wrote this little piece of content script : function detectVariable(){ if(window.my_variable_name || typeof my_variable_name !== "undefined") return true; return false; } After trying for too long, it seems Content Scripts runs in some sandbox. Is there a way to access