javascript screenSize.width code example Example: javascript screen size var w = window.innerWidth; var h = window.innerHeight;