DevTools Logo

BibTeX to JSON Converter

BibTeX to JSON Converter

Turn .bib entries into clean JSON with structured authors, resolved macros and per-entry error isolation.

Runs in your browser
Try an example

BibTeX input

JSON output

Paste BibTeX to see JSON

Entry types, macros, authors and LaTeX accents are normalized locally.

The converter scans entries with a brace-depth-aware parser, so nested braces and quoted values survive intact. Field values are concatenated across # operators, @string macros are expanded, month macros become full names, and optional LaTeX cleanup turns commands such as \"o into Unicode. Author and editor fields are split on ' and ' and normalized into family/given objects, with von particles and suffix forms recognized. Malformed entries are reported with line numbers while the remaining entries still convert. Output is pretty or compact JSON with copy and download.

Journal article

@article{smith2024, title = {A Fine {IEEE} Paper}, author = {Smith, John A. and Doe, Jane}, year = 2024, month = jun, pages = {12--20}}

Produces canonical type 'article', two structured authors, month 'June' and an en-dash page range.

Macro concatenation

@string{jrn = "J. Smith"}
@article{k, author = jrn # " and Doe, Jane"}

The @string value is expanded before concatenation, so the author list splits into two names.

Isolated syntax error

@article{bad, title = {oops
@misc{good, title = {Fine}}

The unclosed entry is reported with its line number; valid entries in the same file are skipped only after the unclosed block.

    Examples

    Article

    Input
    @article{smith2024, title={A Fine Paper}, month=jun, pages={12--20}}
    Output
    { "type": "article", "key": "smith2024", "fields": { "month": "June", "pages": "12–20" } }

    Month macros and double-hyphen page ranges are normalized automatically.

    Macro concatenation

    Input
    @string{jrn = "J. Smith"}
    @article{k, author = jrn # " and Doe, Jane"}
    Output
    authors: [{family: "Smith", given: "J."}, {family: "Doe", given: "Jane"}]

    Macros expand before the author list is split on 'and'.

    About this tool

    BibTeX to JSON Converter turns .bib bibliography files into structured JSON for scripts, wikis and databases. It scans entries with brace-depth awareness, expands @string macros, resolves month abbreviations and parses author lists into family/given objects — the cases that break simple regex converters.

    Conversion is tolerant: an unbalanced brace or malformed field is reported with its line number instead of discarding the entire file. Optional LaTeX cleanup maps accent commands to Unicode, brace protection can be preserved for fields such as {{IEEE}}, and output is available as pretty or compact JSON. Everything runs in the browser; bibliographies are never uploaded.

    What this tool does not do

    • Authors are parsed heuristically; unusual name formats should be reviewed manually.
    • Only a curated set of common LaTeX accent commands is mapped; complex macros remain as text.
    • Nested @string expansion is applied once per field value, not iteratively across transitive macros.
    • Files are capped at a practical browser-editor size; very large bibliographies should be split before pasting.

    How to use this tool

    1. Paste a bibliography

      Load one of the examples or paste a complete .bib file into the editor.

    2. Choose normalization

      Toggle brace preservation, LaTeX cleanup and compact output as needed.

    3. Review the entries

      Check the entry count and the parse-issue list; issues include source line numbers.

    4. Export

      Copy the JSON or download it as bibliography.json.

    Use cases

    Build a citation database

    Convert a BibTeX export into JSON for ingestion by a script or static site.

    Debug a bibliography

    Find entries with unbalanced braces or malformed fields using line-numbered issues.

    Compare author lists

    Normalize 'Last, First' and 'First Last' names into one consistent structure.

    Author object

    FieldMeaning
    familyLast name, including von particles such as 'van Beethoven'.
    givenFirst and middle names; absent for single-word names.
    suffixJr./III form from 'Last, Jr., First' names.
    originalThe unnormalized author string for provenance.

    Citation keys are kept verbatim; entry types are lowercased and common aliases such as @conference map to inproceedings.

    Common mistakes

    Mistake:Expecting a citation style such as APA.

    Fix:This tool emits structured JSON, not formatted references; use a citation generator for output styles.

    Mistake:Stripping case-protection braces blindly.

    Fix:Turn on Keep braces when an journal name depends on capitalization such as {IEEE}.

    Mistake:Assuming a parse error discards everything.

    Fix:Each malformed entry is isolated and reported; the rest of the file still converts.

    Frequently asked questions

    How are multiple authors handled?

    The author (or editor) field is split on ' and ' at brace depth zero. 'Last, First' names become {family, given}, 'First Last' names are reversed, three-part forms capture a suffix, and lowercase particles such as 'van' become part of the family name. The original string is kept alongside the structured form.

    What happens to braces in fields?

    Braces are removed by default so {{IEEE}} becomes IEEE. Turn on Keep braces to preserve them for case protection. Nested braces inside a field are handled correctly by the depth-aware scanner.

    Are month macros converted?

    Yes. The standard jan–dec macros (and full month names) resolve to English month names such as 'June'. Quoted values like "June" pass through unchanged. You can turn month normalization off if you need the raw macro.

    Can it handle @string definitions?

    Yes. @string values are stored in a macro table and expanded wherever a field refers to them, including inside # concatenation such as author = jrn # " and Doe, Jane". User definitions override the built-in month macros.

    Is my bibliography uploaded?

    No. Parsing, macro resolution, LaTeX cleanup and JSON emission all happen in your browser tab. Nothing is sent to a server or stored in localStorage.

    References & standards