remove html tag from dom code example Example: remove the html tags in javascript let strippedString = originalString.replace(/(<([^>]+)>)/gi, "");