how to get content of the current page with jquery or JS June 7, 2023 by Tarik You could use the javascript DOM API like this: var headContent = document.getElementsByTagName('head')[0].innerHTML;