As previously mentioned, single quotes and double quotes can both be used in JavaScript. Sometimes you need to quote within and quote and alternating quotes can be tedious. Another way of using quotes within quotes is to escape the inner quotes.