if li has width is equal then apply css jquery code example Example: jquery set width $(".example").width("px");