jquery split string after everry 2 character code example Example: split every n character js var str = 'abcdefghijkl'; console.log(str.match(/.{1,3}/g));