# Convert

> JSON, YAML, TOML, XML, CSV, SQL, timestamps, cron, colors, and cases.

Convert between the data formats you actually ship: JSON, YAML, TOML, XML, CSV, TSV, SQL inserts, Unix time, cron, CSS colors, identifier case, IPv4, hex, binary, integer bases, byte sizes, CSS units, and durations. All parsing happens in the tab. There is no conversion API.

If you need to convert photos instead of data files, try [Online Image Converter](https://onlineimageconverter.net/). If you need to merge, split, or compress a PDF, try [LoveThisPDF](https://lovethispdf.com/).

## Data formats

- [JSON ↔ YAML](https://toolbuddy.dev/tools/json-yaml.md): Convert JSON to YAML and YAML back to JSON in the browser. Paste a config, Kubernetes snippet, or API fixture and copy the other format. Parsing uses js-yaml locally. Documents are never posted to a converter.
- [JSON ↔ TOML](https://toolbuddy.dev/tools/json-toml.md): Convert JSON objects to TOML and TOML documents back to JSON in the browser. Handy for Cargo.toml, pyproject, and app config fragments. Parsing stays on-device.
- [JSON ↔ XML](https://toolbuddy.dev/tools/json-xml.md): Convert JSON objects to XML and XML documents back to JSON. Useful for SOAP leftovers, RSS, and mixed API stacks. XML is parsed with the browser DOMParser so payloads stay on the device.
- [JSON ↔ CSV](https://toolbuddy.dev/tools/json-csv.md): Turn an array of JSON objects into CSV, or parse CSV headers into JSON objects. Quote-aware parsing runs in the tab so spreadsheets of IDs and emails are not uploaded to a conversion service.
- [CSV ↔ TSV](https://toolbuddy.dev/tools/csv-tsv.md): Convert comma-separated values to tab-separated values and back, preserving quoted fields. A small delimiter swap for dumps you would rather not paste into a spreadsheet SaaS.
- [JSON to Code](https://toolbuddy.dev/tools/php-array.md): Convert JSON into JS, Python, or PHP literals. Objects become dicts or arrays with key => value pairs. Conversion is a local string transform.
- [JSON to TypeScript](https://toolbuddy.dev/tools/json-typescript.md): Infer TypeScript interfaces from a JSON sample. Nested objects become named interfaces, and keys missing from some objects in an array are optional. Conversion stays in the tab.

## SQL and CSV

- [JSON to SQL](https://toolbuddy.dev/tools/json-sql.md): Turn a JSON object or array of objects into SQL INSERT statements. Set a table name, copy the query, and keep rows on the device instead of pasting fixtures into a hosted converter.
- [CSV to SQL](https://toolbuddy.dev/tools/csv-sql.md): Turn CSV into SQL INSERT statements. The header row becomes columns. Rows stay in the tab.
- [CSV Query](https://toolbuddy.dev/tools/csv-query.md): Preview CSV as a table and run a small SQL subset: SELECT, WHERE, ORDER BY, LIMIT. Querying is in-memory in this tab.

## Time and dates

- [Timestamp Converter](https://toolbuddy.dev/tools/timestamp-converter.md): Convert Unix timestamps, milliseconds, and ISO 8601 dates in both directions. See UTC and local time side by side, generate a 'now' epoch, and copy values for logs, databases, and APIs without a round trip to a conversion API.
- [Timezone Compare](https://toolbuddy.dev/tools/timezone-compare.md): Show an instant in several IANA time zones using Intl. Paste ISO 8601 or leave empty for now. Conversion is local.
- [Duration Converter](https://toolbuddy.dev/tools/duration-converter.md): Convert durations between milliseconds, seconds, minutes, hours, days, and ISO 8601 (PT1H30M). Paste 1h 30m, 5400s, or a timeout from a config file. Parsing stays on-device.
- [Cron Parser](https://toolbuddy.dev/tools/cron-parser.md): Explain a cron expression in plain English, list the next run times in your local time zone, and edit fields or presets. Paste a 5- or 6-field crontab line. Parsing is local, so job schedules never hit a cron API.

## Numbers and bytes

- [Number Base Converter](https://toolbuddy.dev/tools/number-base.md): Convert integers between binary, octal, decimal, and hexadecimal. Uses BigInt so large IDs and bit masks still round-trip. All math is local. There is no integer-conversion API.
- [Big Number](https://toolbuddy.dev/tools/big-number.md): Add, subtract, multiply, divide, and raise integers larger than Number.MAX_SAFE_INTEGER using BigInt. Math stays in the tab.
- [Hex Converter](https://toolbuddy.dev/tools/hex-text.md): Encode UTF-8 text as hexadecimal bytes and decode hex back to text. Inspect packet dumps, color-ish strings, and binary-safe debug output without a remote hex encoder.
- [Binary Converter](https://toolbuddy.dev/tools/binary-text.md): Convert text to binary and binary back to text. Inspect UTF-8 bit patterns, homework encodings, and simple wire dumps. Conversion stays on-device with copyable 0s and 1s.
- [IPv4 Converter](https://toolbuddy.dev/tools/ip-converter.md): Convert IPv4 addresses between dotted decimal, unsigned integer, hex, and dotted binary. Useful when a database stores IPs as numbers. Parsing is local IPv4 math. No geo lookup and no 'what is my IP' lookup.
- [Data Size Converter](https://toolbuddy.dev/tools/data-size-converter.md): Convert bytes between decimal units (KB, MB, GB, TB) and binary units (KiB, MiB, GiB, TiB). See why a 500 GB disk shows up as 465 GiB. The math runs in the tab.

## Colors, CSS, and naming

- [Color Converter](https://toolbuddy.dev/tools/color-converter.md): Convert colors between HEX, RGB, HSL, CMYK, and related CSS notations. Preview swatches, copy values for design tokens, and translate picker output into code. Runs entirely in the tab so brand palettes never hit a third-party converter.
- [Color Contrast](https://toolbuddy.dev/tools/color-contrast.md): Check WCAG contrast between two colors. Paste HEX, RGB, or HSL for foreground and background. Ratio math is local.
- [CSS Unit Converter](https://toolbuddy.dev/tools/css-unit-converter.md): Convert CSS lengths between px, rem, em, pt, pc, in, cm, and mm. Set the base font size to match your root, then copy the value you need. Conversion is local.
- [Case Converter](https://toolbuddy.dev/tools/case-converter.md): Convert identifiers between camelCase, PascalCase, snake_case, kebab-case, CONSTANT_CASE, and URL slugs. Paste one name or a list, one per line. Conversion is a local string transform.
