var s = document.createElement("script"); s.type = "text/javascript"; s.src = "http://somedomain.com/somescript"; $("head").append(s);