# Join Array

Join array items into a single string with a custom separator

> Canonical page: https://elysiatools.com/en/tools/join-array

- **Category:** Data Processing

- **Keywords:** array, join, string, separator, combine

## Overview

Join array items into a single string using a custom separator.

**Highlights:**
- Accepts a JSON array
- Uses the separator exactly as provided
- Objects/arrays are JSON-stringified before joining

**Example:**
- Array: `["a", "b", "c"]`
- Separator: `-`
- Result: `a-b-c`

## Inputs

- **Array** (textarea): Enter a JSON array
- **Separator** (text): String placed between items

## When to use

- When you need to combine array elements into a comma-separated string for reports or exports.
- When preparing list data for display in user interfaces, logs, or documents.
- When converting structured JSON arrays into plain text for APIs or data processing pipelines.

## How it works

- Input a valid JSON array into the 'Array' field, such as \["item1", "item2"\].
- Specify a custom separator in the 'Separator' field; it defaults to a comma and space (", ").
- The tool processes each element, converting objects or arrays to JSON strings as needed.
- It outputs a single string with all elements joined by the provided separator.

## Use cases

- Generating CSV-like strings from array data for spreadsheet imports or data exports.
- Formatting lists for readable output in web applications, reports, or terminal displays.
- Preparing array data as a single string for APIs, configuration files, or logging systems.

## Frequently asked questions

### What format must the array input be in?

The array must be in valid JSON format, like ["value1", "value2"].

### Can I use special characters or an empty string as the separator?

Yes, the separator can be any string, including special characters or an empty string for direct concatenation.

### How are non-string elements like numbers or objects handled?

Non-string elements are converted to strings; objects and arrays are JSON-stringified before joining.

### Is there a limit on the array size or number of elements?

The tool supports arrays of typical sizes, but very large arrays may affect performance.

### What is the default separator if none is provided?

The default separator is a comma followed by a space (", ").

## Related tools

- [ECharts Theme Token Extractor](https://elysiatools.com/en/tools/echarts-theme-token-extractor): Extract design tokens — colors, numbers, font sizes and strings — from an ECharts theme JSON and export them straight into your design system. Paste a theme object (the kind registered via echarts.init(dom, themeName)) and the tool walks every leaf, tagging each color (with optional named/rgb → hex normalization), spacing number, font size and string, then emits clean CSS variables, a Tailwind theme.extend config, Style Dictionary tokens.json, or SCSS variables. Bridges the gap between an ECharts visualization theme and Figma/CSS/Tailwind design tokens without copying each value by hand.
- [Jupyter Notebook to Reproducible Script Linearizer](https://elysiatools.com/en/tools/jupyter-notebook-to-reproducible-script-linearizer): Turn .ipynb into a # %% Python script and detect out-of-order, hidden, and deleted state
- [Compact Array](https://elysiatools.com/en/tools/compact-array): Remove falsey values from array using lodash _.compact
- [JSON Key Extractor](https://elysiatools.com/en/tools/json-key-extractor): Extract all keys from JSON objects with multiple output formats. Perfect for analyzing JSON structure, documentation generation, and understanding complex nested objects.
- [OCR PDF to Structured JSON Bridge](https://elysiatools.com/en/tools/ocr-pdf-to-structured-json-bridge): Extract the PDF text layer with geometry (lines by y-position, tables by column gaps, headings by font size, colon key-value pairs), then fill a user-supplied JSON Schema field by field — labels matched by normalized keys, values coerced to declared types and validated with ajv.
- [Podcast Chapter Marker Builder](https://elysiatools.com/en/tools/podcast-chapter-marker-builder): Build every podcast chapter format from one timecoded list: Podcasting 2.0 JSON + RSS tag, ID3v2.4 CHAP+CTOC burned into an MP3, Vorbis comments, mp4chaps, YouTube timestamps and SRT, with a per-player support matrix.
- [Pull Values](https://elysiatools.com/en/tools/pull-values): Remove specific values from an array using lodash _.pull
- [TOML / INI / HCL / .env / Nix / dotenv ⇄ Kubernetes ConfigMap & Secret Config Format Bridge](https://elysiatools.com/en/tools/toml-ini-hcl-envfile-nix-dotenv-kubernetes-configmap-secret-config-format-bridge): Convert configuration files between dotenv .env, TOML, INI, Java .properties, YAML, JSON, HCL (Terraform/Vagrant native syntax) and Nix attribute sets, and emit Kubernetes ConfigMap or Secret manifests. Template placeholders (${VAR}, {{var}}, envsubst) are preserved verbatim, type inference provenance (string/int/float/bool/list) is tracked, HCL block labels fold into nested keys, and a round-trip diff calls out non-equivalent settings — dropped keys, re-typed values and rewrites — instead of coercing them silently.

## Samples

- [QR Code Samples](https://elysiatools.com/en/samples/qrcode-samples): Sample QR code images for testing QR code reading and generation tools
- [Distributed Tracing Samples](https://elysiatools.com/en/samples/distributed-tracing-samples): Comprehensive distributed tracing examples using Jaeger, OpenTelemetry, and other modern observability tools for microservices architecture
- [ELK Stack Log Analysis Samples](https://elysiatools.com/en/samples/elk-stack-samples): Comprehensive ELK Stack (Elasticsearch, Logstash, Kibana) samples for log aggregation, processing, and visualization in distributed systems
- [Grafana Advanced Application Samples](https://elysiatools.com/en/samples/grafana-samples): Comprehensive Grafana samples covering advanced dashboard design, alerting configurations, data source integrations, and plugin development
