jQuery innerWidth() Method Last Updated : 10 Jul, 2023 Comments Improve Suggest changes Like Article Like Report The innerWidth is an inbuilt method in jQuery that is used to return the width of the first matched element. Syntax: $(selector).innerWidth() Here selector is the selected element. Parameters: It does not accept any parameters. Return value: It returns the width of the selector. jQuery code to show the working of innerWidth() method: Example: Here is an example of the above-explained method. html <!DOCTYPE html> <html> <head> <script src= "https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"> </script> <script> //jQuery code to demonstrate innerWidth function // document ready $(document).ready(function () { // on clicking the paragraph $("p").click(function () { // innerWidth document.getElementById("demo").innerHTML = "innerWidth = " + $("div").innerWidth(); }); }); </script> </head> <body> <h2 style="color: green;"> GeeksforGeeks </h2> <div style="height: 100px;width: 200px; background-color: blue"> </div> <p> Click here to know innerWidth </p> <p id="demo"></p> </body> </html> Output: Comment S ShivamKD Follow Improve S ShivamKD Follow Improve Article Tags : Misc Web Technologies JQuery jQuery-Methods Explore jQuery Tutorial 8 min read Getting Started with jQuery 4 min read jQuery Introduction 7 min read jQuery Syntax 2 min read jQuery CDN 4 min read jQuery SelectorsJQuery Selectors 5 min read jQuery * Selector 1 min read jQuery #id Selector 1 min read jQuery .class Selector 1 min read jQuery EventsjQuery Events 4 min read jQuery bind() Method 2 min read jQuery blur() Method 1 min read jQuery change() Method 2 min read jQuery EffectsjQuery animate() Method 2 min read jQuery clearQueue() Method 2 min read jQuery delay() Method 2 min read jQuery HTML/CSSjQuery addClass() Method 2 min read jQuery after() Method 1 min read jQuery append() Method 2 min read jQuery TraversingjQuery | Traversing 4 min read jQuery add() method 1 min read jQuery addBack() Method 2 min read Like