# How to convert an Array to a String in JavaScript

> Learn how to convert an array to a string in JavaScript using the toString() method or join(), which lets you pass a custom separator between elements.

Author: [Flavio Copes](https://flaviocopes.com/about/) | Published: 2020-03-09 | Topics: [JavaScript](https://flaviocopes.com/tags/js/) | Canonical: https://flaviocopes.com/how-to-convert-array-to-string-javascript/

Using the `toString()` method on an array will return a string representation of the array:

```js
const list = [1, 2, 3, 4]
list.toString()
```

Example:

![How to convert an Array to a String in JavaScript](https://flaviocopes.com/images/how-to-convert-array-to-string-javascript/Screenshot_2020-02-28_at_16.56.21.png)

The `join()` method of an array returns a concatenation of the array elements:

```js
const list = [1, 2, 3, 4]
list.join()
```

We can pass a parameter to this method to add a custom separator:

```js
a.join(', ')
```

Example:

![How to convert an Array to a String in JavaScript](https://flaviocopes.com/images/how-to-convert-array-to-string-javascript/Screenshot_2020-02-28_at_16.58.31.png)
