Make sure you specify an empty string to .join, otherwise you'll get commas between each character:

Copy"McDonalds".split("").reverse().join(""); // "sdlanoDcM"
Answer from p.s.w.g on Stack Overflow
🌐
Hashnode
kirsty.hashnode.dev › javascript-string-manipulation-how-to-use-split-reverse-and-join
JavaScript: Split, Reverse, Join Strings
October 11, 2024 - For example, using the splitHyphen ... into a string, with spaces between each word. The reverse() method changes the order of elements in an array to be the opposite of what it was....
🌐
Medium
medium.com › sonyamoisset › reverse-a-string-in-javascript-a18027b8e91c
Reverse a String in JavaScript. This article is based on Free Code Camp… | by Sonya Moisset | iDevOI | Medium
November 25, 2016 - The split() method splits a String object into an array of string by separating the string into sub strings. The reverse() method reverses an array in place. The first array element becomes the last and the last becomes the first.
🌐
YouTube
youtube.com › watch
JavaScript How To Reverse String (split, reverse join, for loop) - YouTube
Sign Up 👻👻👉 https://semicolon.dev/YouTube(We're free online community, meet other makers!)#javascript #js #coding How to reverse a string in javascript ...
Published   June 5, 2022
🌐
GeeksforGeeks
geeksforgeeks.org › javascript › reverse-a-string-in-javascript
Reverse a String in JavaScript - GeeksforGeeks
split(): This method splits a string into an array of substrings based on a specified delimiter. reverse(): This method reverses the order of elements in the array, swapping the first element with the last, and so on. join(): This method combines ...
Published   December 20, 2025
🌐
DEV Community
dev.to › ofthewildfire › javascript-string-manipulation-how-to-use-split-reverse-and-join-4ojf
JavaScript String Manipulation: How to Use Split, Reverse, and Join - DEV Community
October 11, 2024 - For example, using the splitHyphen ... into a string, with spaces between each word. The reverse() method changes the order of elements in an array to be the opposite of what it was....
🌐
CodePen
codepen.io › susanwinters › pen › KdxmzY
JavaScript - Reverse a String .split('').reverse().join('')
function reverseString(str) { var strReverse = str.split('').reverse().join(''); return strReverse; } reverseString("hello");
🌐
freeCodeCamp
freecodecamp.org › news › reversing-a-string-in-javascript-invert-a-string-with-the-js-reverse-method
Reversing a String in JavaScript – Invert a string with the JS .reverse() Method
November 7, 2024 - In general, we split the particular string into an array using either the spread operator or the split() method. Then we use the reverse() method, which can only be used to reverse elements in an array.
🌐
YouTube
youtube.com › manin chiev
Reverse a string in JavaScript using the split, reverse, and join methods - YouTube
This video is going to show reversing a string by first converting it to an array of characters, reversing the array, and then converting it back to a strin...
Published   November 24, 2023
Views   57
Find elsewhere
🌐
DEV Community
dev.to › onlinemsr › javascript-reverse-string-3-best-ways-to-do-it-8co
JavaScript Reverse String: 3 Best Ways To Do It - DEV Community
July 3, 2023 - Using the JavaScript parseFloat() or JavaScript parseInt() methods depending on the data type, convert the generated string to a number. const number = -12345.67; const reversedString = number .toString() .split('') .reverse() .join(''); let reversedNumber = parseFloat(reversedString) * Math.sign(number); console.log(reversedNumber); // Output: -76.54321 ·
🌐
GitHub
gist.github.com › shahrzadmn › 6816652b25ed4268ec2b
Reversing a string by using split, reverse and join methods in JavaScript. · GitHub
Reversing a string by using split, reverse and join methods in JavaScript. - bonfire-reverse-a-string#.js
🌐
Medium
medium.com › @jsutcliffe1991 › javascript-array-method-simply-reverse-a-string-reverse-vs-toreversed-join-649e7a4f5e97
Javascript Array Method: Simply Reverse a String / .reverse() vs .toReversed() / .join() | by James Robert Sutcliffe | Medium
July 6, 2023 - To complete our task we use the .join() method. This method gives us our correct output when declared on reversed arrays from both of our array reversal methods. I see the .join() method as the opposite of the .split() method.
🌐
Medium
medium.com › @josesoal › two-very-useful-function-in-javascript-split-and-join-3df16b55768
Two Very Useful Functions in Javascript: split() and join() | by José Soncco | Medium
May 25, 2020 - The arrow function simply takes one age (string) as parameter convert it to an array, reverse it, and the convert back to a string. The next problem is given a string of ages, we want to know if there is anyone with more than 40 years. The following snippet solves the problem. In this case we only want to return a boolean value, so we just need the split function and not the join function.
🌐
IQCode
iqcode.com › code › javascript › javascript-splitreversejoin
javascript .split().reverse.join Code Example
reverse an string in array creating a function that reverse a string js reverse string function how do you reverse a string of words in javascript reverse string using substring js how to reverse text js reverse using split reverse join in js' js reverse str how to reverse substring javascript reverse function javascript string how to reverse a string is js how to reverse the string javascript reverse striung js reverse string prototype javascript example reverse is a string or array method javascript string js revert reverse string without using reverse function in javascript javascript how to print a string in reverse reverse strig js how to reverse a string in js?
🌐
LeetCode
leetcode.com › problems › reverse-words-in-a-string-iii › solutions › 101990 › javascript-solution-using-mapsplitreversejoin
JavaScript solution using map/split/reverse/join
Can you solve this real interview question? Reverse Words in a String III - Given a string s, reverse the order of characters in each word within a sentence while still preserving whitespace and initial word order. Example 1: Input: s = "Let's take LeetCode contest" Output: "s'teL ekat edoCteeL tsetnoc" Example 2: Input: s = "Mr Ding" Output: "rM gniD" Constraints: * 1
🌐
CoreUI
coreui.io › answers › how-to-reverse-a-string-in-javascript
How to reverse a string in JavaScript · CoreUI
September 22, 2025 - This method chains three operations: split('') converts the string into an array of individual characters, reverse() flips the order of elements in the array, and join('') combines the characters back into a string.
🌐
YouTube
youtube.com › watch
How to Reverse String in JavaScript using Built-in Functions ...
Enjoy the videos and music you love, upload original content, and share it all with friends, family, and the world on YouTube.
🌐
C# Corner
c-sharpcorner.com › article › reverse-a-string-in-javascript
Reverse A String In JavaScript
June 27, 2023 - And in the final step, we're joining the array elements, i.e., string characters, using the join method. Instead of writing each operation in a separate statement, we could chain the methods and perform all the operations in a single line. const str = 'hello world!'; const strReverse = str.split('').reverse().join(''); console.log(strReverse); // Output: !dlrow olleh
🌐
ReqBin
reqbin.com › code › javascript › lqai57s8 › javascript-reverse-string-example
How do I reverse a string in JavaScript?
let str = 'JavaScript Reverse String Example'; let reversed = str.split('').reverse().join(''); console.log(reversed);