Home / Science / Research toolkit / Writing and publishing / BibTeX cleaner and reference formatterTool #802

BibTeX cleaner: fix ADS exports, merge duplicates, expand \apj journal macros, protect capitals, export RIS, CSL-JSON or a formatted reference list

Paste or open a .bib file and get it back clean: duplicates merged by DOI or title, journal macros such as \apj and \mnras written out, acronyms protected, page dashes, months and DOIs tidied, fields you don't want removed and entries sorted. Export the clean .bib, an APA-like, numbered or AAS-like reference list, RIS or CSL-JSON.

Keep it one tap away for everyday use.

Bookmark BibTeX cleaner and reference formatter?

Press Ctrl + D now. Your browser opens its own bookmark box, where you choose the name and folder.

  1. BibTeX
  2. Clean-up
  3. Duplicates
  4. Export
Nothing is uploadedWorks offline once open

Your BibTeX

BibTeX text (.bib or .txt), up to 5 MB and 20,000 entries.

Paste entries from a reference manager, Google Scholar or an ADS export, or open your .bib file. You can also drop a file on the box. Broken entries are reported with their line number and the rest are still read.

Clean-up

Journal macros: ADS writes journals as \apj or \mnras, which only work with the AAS macro file; this writes the name instead. Capitals: BibTeX styles may turn titles to lower case; braces keep words such as {DNA} as typed. Merge duplicates keeps the fuller of two entries with the same DOI, or with the same title and first author, and adds any fields only the other had. Unwrap removes the braces ADS puts around a whole title, which stop styles from changing any letter. Bare DOIs removes https://doi.org/ so styles do not print it twice.

What it does

A reference list built over years from journal websites, Google Scholar and ADS usually has the same paper twice under two keys, journals written as \apj that break without the AAS macro file, titles whose acronyms come out as “Dna” and page ranges with the wrong dash. This page reads your BibTeX and fixes all of that in one go, on your device:

  • Reads anything BibTeX reads: entries in braces or parentheses, @string abbreviations, # joins, @preamble and @comment. A broken entry (a missing brace, say) is reported with its line number and the rest of the file is still read.
  • Merges duplicates: entries with the same DOI (ignoring https://doi.org/ and letter case), or with the same title and first author when there is no DOI. The fuller entry is kept and gains any fields only the other had, and the page tells you which key to cite.
  • Writes journal macros out as the short name (ApJ, MNRAS, A&A) or the full name, for about 55 AAS macros used by ADS.
  • Protects capitals: words such as DNA, pH, CO2 or HII are wrapped in braces so styles that lower-case titles leave them alone. Protect every capital also keeps proper names such as Milky Way.
  • Tidies fields: field names in lower case, page ranges with --, months as jan to dec, DOIs without the URL part, empty fields and the fields you list (by default abstract, file, keywords and adsnote) removed, biblatex journaltitle and date turned into journal, year and month, and a key made for any entry that has none.
  • Exports the clean .bib, a reference list in an APA-like, numbered (IEEE-like) or AAS-like style, RIS for EndNote, Zotero or Mendeley, and CSL-JSON for Zotero or Pandoc.

How to use it

  1. BibTeX. Paste your entries or open your .bib file.
  2. Clean-up. Choose how to write journal macros, how to protect capitals, the order and the fields to remove. Each option takes effect at once.
  3. Duplicates. Read the list under Result: each merged duplicate names the key that was kept, so you can change your \cite commands. What changed lists every edit, entry by entry.
  4. Export. Pick what to show, then copy or download it. A reference list can be copied for Word with its italics, or downloaded as an image, PDF or Word file.

Worked example

Press Use the example. It has five made-up entries in the shape of an ADS export. The page reads 5 entries, merges 1 duplicate (the entry lovelace2021 has the same DOI as 2021ApJ...900...12L, written as a URL in capitals) and writes 4 entries, 3 of them changed. In the cleaned file, journal = {\apj} becomes journal = {ApJ}, the title loses the braces ADS put around it and becomes Faint {HII} regions in the outer disk of a made-up galaxy, pages 12-20 become 12--20, and the keyless conference entry gets the key smith2020.

The APA-like list then starts with Babbage, C. (2018). Engines of Calculation. Example Press., and the AAS-like list gives Lovelace, A., Babbage, C., & van der Berg, M. 2021, ApJ, 900, 12, doi: 10.5555/example.0001.

Tips

  • Keep a copy of the original file. Cleaning changes keys only for entries that had none or clashed, but merged duplicates disappear.
  • If your journal provides the AAS macros (AAS journals, MNRAS and A&A do), you can keep \apj as it is; otherwise write the names out.
  • Check names in braces such as {van der Berg} or {The Example Collaboration}: braces keep them together as a family name, which is usually what you want.
  • The reference lists are a quick, readable version of your references, not a replacement for the journal’s own BibTeX style.

FAQ

Will it change my citation keys? Only when an entry has no key, or two different entries share one; the page tells you which. Merged duplicates keep the key of the fuller entry.

Why does my title still come out in lower case? Choose Protect every capital, or put braces around the words yourself. The journal’s style decides the case of anything not in braces.

Is my file uploaded? No. It is read and cleaned on this page and never leaves your device.

Where the numbers come from

  • The parser follows the BibTeX file format (entries, @string, @preamble, @comment, # joins) and BibTeX's rules for splitting names, as general knowledge. It was checked against the bibtexparser and pylatexenc Python libraries.
  • Journal macro names (\apj, \mnras, \aap and others) and the journal names they stand for are general facts used by the AAS macro file and ADS exports.
  • The reference styles are written by fibub to resemble APA, IEEE and AAS reference lists; they are not the official styles.
  • The example entries, bibcodes and DOIs (10.5555 is a test prefix) are made up.

Standard scientific values, such as constants, atomic weights and melting points, are facts found in every textbook; we name where ours were checked. If you are an author or publisher and want a value, a credit or a table changed or removed, tell us and we will act quickly.

Last updated 2026-11-09.

Related tools

File converter #4 Convert pictures to PDF and back, PDF to text, Word to HTML or Markdown, and Excel, CSV and JSON between each other. Nothing is uploaded. Author list and affiliation formatter #801 Type your authors and affiliations once, in a simple line format, and get the author block for AASTeX, MNRAS, A&A, REVTeX or elsarticle, a numbered superscript list for Word, plain text or JATS-style XML. Repeated affiliations are merged and numbered in order, ORCID iDs are checked, and the corresponding author is marked. Abstract word counter #806 Paste an abstract (plain text or LaTeX) and see its words, characters with and without spaces, sentences and keywords against a limit you set. The part over the limit is marked, LaTeX commands, citations and comments can be left out of the count, and the most repeated words are listed. Response to reviewers builder #807 Paste the reviewers' reports and the page splits them into numbered points for each reviewer, keeping their numbers and major/minor groups. Write a response and the change made under each point, see which are still unanswered, and download the letter as Word, PDF, image, LaTeX or Markdown. Your draft is kept in this browser only if you tick the box. Equation converter (LaTeX and MathML) #803 Type or paste LaTeX maths and get MathML you can paste into Word, LibreOffice or a web page, with a live preview drawn from that MathML. Or paste MathML and get LaTeX back. Fractions, roots, sums, integrals, matrices, accents and Greek letters. Errors say what is wrong and where. Table converter (LaTeX, Markdown, HTML) #804 Paste cells from Excel, Google Sheets or LibreOffice, or open a CSV or Excel file, and get a LaTeX table (booktabs rules, caption and label, siunitx decimal alignment), a Markdown table or an HTML table. Special characters are escaped and numbers can be rounded the way you would on paper.