jquery add attr that has no value code example Example: jquery add attribute without value $('body').attr('data-body','');