JavaScript Reverse

JavaScript has no native reverse for strings, so we chain three array methods: split("") breaks the string into characters, reverse() flips the array, and join("") glues it back. Another textbook chaining example.

Syntax

str.split('').reverse().join('')

Examples

Input Arguments Output
"hello" "olleh"

Gotchas

  • split("") breaks emoji and some Unicode characters apart; use [...str] for correct code-point handling.

Try it live

Type your input and see Reverse transform it instantly.

Reverse()

Type above to see the result…

Want to go further? Chain Reverse with other functions, pipe one output into the next and watch your data transform in the visual Playground.

Related functions

© 2026 Heifara Buval