how to put a backslash in a string javascript code example Example: javascript backslash You have to type a double backslash. Like: \\