openpathogen About

What is openpathogen, and how does it work?

openpathogen is an open-source platform that screens for antimicrobial resistance and virulence genes in sequencing reads.

It uses KMA v1.5.1 for read mapping, fastp 0.22 for quality control and, if you ask for it, Deacon 0.18.0 to remove human reads. All three are compiled from source to WebAssembly.

Your data is analysed on your own computer and is never uploaded anywhere. This makes it safe to use with clinical or unpublished data.

There is no need for account creation and no server. The only downloads are the app, the WebAssembly engines and the databases. More details are in the privacy section.

Databases are downloaded once, checked against pinned SHA-256 hashes and cached in the browser. Repeat runs can therefore start at once. The first run against a large database might take some time while it fetches the databases from Zenodo.

Privacy

Nothing you upload leaves your machine. A website ofcourse still makes some network requests. This is the full list of requests, so you can check it against the source code or your browser's network inspector.

Your sequencing files (FASTQ)
Never uploaded and never written to disk. Files are read into memory, processed by WebAssembly and gone when you close the tab. No cookies and no accounts.
Page views (Cloudflare, the host)
The site is served by Cloudflare, which sees each request and your IP address like any webpage host does. Cloudflare may add scripts of its own under /cdn-cgi/ for bot detection, and its Web Analytics beacon from cloudflareinsights.com when that is switched on; neither uses cookies or cross-site tracking. There is no other analytics provider and no tracking code in the app. The site's response headers carry a Content-Security-Policy that limits where the page may connect: this site, Zenodo, EMBL-EBI and the Cloudflare beacon. You can read it in your browser's network inspector, and the file that sets it is _headers in the source code.
Databases, CABBAGE snapshot and engines (this site or Zenodo)
The KMA, fastp and Deacon engines ship with the page. The ResFinder, CARD and VFDB indexes and the CABBAGE snapshot are downloaded once from this site or from Zenodo and cached locally. PointFinder's references for your species (under 1 MB) come from this site the first time you give a species it covers. The human index for Deacon (239 MB) is downloaded from this site the first time you tick Remove human reads. Every file is checked against a pinned SHA-256 hash before it is used. A corrupted or altered download is rejected. After the first visit a service worker keeps the page and the engines, so openpathogen loads and runs offline with the databases it has already cached.
Fetching a public run (only when you ask)
If you fetch a run by accession or load the example, the accession and your IP address go to EMBL-EBI (ENA). ENA then knows which public run you fetched. The reads are cached in your browser like the databases.

That is all. To remove cached data (indexes, the human index, snapshot, example and fetched runs), use Clear cached data under the database selector on the main page.

Getting started

  1. Drop your read files (.fastq or .fastq.gz) on the page or choose them. For paired-end reads, you can select both files at once and they are matched to R1 and R2 by name. The read type is also set for you as: two files are paired-end, and a single file is Nanopore or single-end depending on its read lengths. You can change it with the Read type buttons if needed. Or try the example: S. aureus USA300_TCH1516 (SRR10341524), a 48 MB MiSeq run of the community-associated MRSA reference strain, downloaded from ENA. The reads are cached in your browser. You can also fetch any public run by accession (SRR, ERR or DRR) with Fetch reads. The species and read type are set from the ENA record, and the R1 and R2 files are matched by name; when ENA lists a third file of unpaired reads beside them, it is skipped. Files are limited to 1 GB each.
  2. Tick the databases to screen against. ResFinder is preselected, and any combination of ResFinder, CARD and VFDB runs in one go. PointFinder is ticked too, and runs whenever the species is one it covers. Turn on fastp quality control if you want trimming and filtering, and open its settings to change the defaults. For samples with human DNA, such as swabs or clinical metagenomes, tick Remove human reads.
  3. Enter the species if you know it. This is optional, and adds CABBAGE tested-resistance rates to the report. You can also set it on the results page.
  4. Select Run. Progress is written to the Logs panel, which shows the exact KMA, fastp and Deacon commands and their output.

Databases

ResFinder 2.6.0
Acquired antimicrobial resistance genes (CGE). Apache License 2.0.
CARD 4.0.1
Comprehensive Antibiotic Resistance Database, protein homolog model. Free for non-commercial research and academic use under CARD's terms; commercial use needs a licence from McMaster University.
VFDB
Virulence Factor Database, set A (core virulence factors). CC BY-NC 4.0, so non-commercial use only; for commercial use, contact the VFDB team.
PointFinder 4.1.1
Chromosomal mutations linked to resistance, with the wild-type genes they are found in, for Campylobacter, E. coli (Shigella too), Enterococcus faecalis and faecium, Helicobacter pylori, the Klebsiella pneumoniae complex, Mycobacterium tuberculosis, Neisseria gonorrhoeae, Salmonella and Staphylococcus aureus (CGE). Apache License 2.0. Two of its Klebsiella genes are replaced (see the notes).

The indexes openpathogen downloads are built from these databases and carry the same terms, whichever site they come from. The full list of licences is in THIRD_PARTY_NOTICES.

Human read removal

Reads from swabs, tissue and other clinical samples can contain human DNA. Tick Remove human reads and Deacon removes the reads that match the human pangenome before the databases run. It runs on your device like the rest of the analysis, after fastp when fastp is on. The report says how many reads were removed, and the remaining reads can be downloaded from the Human reads card below the report.

Deacon compares short DNA words (minimizers) of each read with an index of the human pangenome: Deacon's panhuman-1 index, built from the first release of the Human Pangenome Reference Consortium, CHM13 and GRCh38, minus the words also found in bacteria and viruses. A read counts as human when at least 2 of its words, and 1% of them, are in the index. Paired reads are judged together and removed together. openpathogen uses the compact version of the index (k=31, w=61), stored as a 239 MB filter that downloads once.

In testing, the browser version gave the same output as Deacon on the command line. It removed 98.5% of the reads of a human genome sequencing run, 14.7% of a vaginal swab metagenome and 26 of the 515,164 reads of the example isolate. The details are in deacon/WASM_BUILD.md. Deacon needs at least two matching words per read or pair, so very short single-end reads are more likely to be missed. It filters about 15 MB of gzipped reads per second on a recent laptop.

Deacon removes most human reads, but not all of them, so removal alone does not make a sample anonymous. Check the rules that apply to your samples before sharing the reads.

The report and CABBAGE rates

The results open with a report. Resistance genes are grouped by drug class, and each gene lists the antibiotics it affects, from ResFinder's curated phenotype table. Beta-lactams are grouped the way they are prescribed (penicillins, cephalosporins by generation, carbapenems), and well-known gene types are labelled: ESBL, AmpC, carbapenemase and methicillin resistance. CARD hits are matched to ResFinder genes by name. CARD genes that ResFinder has no drug class for, such as efflux pumps, are listed separately. The report then lists the drug classes with no acquired gene. Genes that ResFinder marks as natural to the sample's species, such as blaOXA-51 in Acinetobacter baumannii, are shown in their own section with ResFinder's conditions (for blaOXA-51, carbapenem resistance only with ISAba1 upstream) and are not counted as acquired resistance, so the species has to be given. Partial genes, found at the identity threshold but covering less of the gene than the coverage threshold asks, or cut short by a stop codon, are listed in a section of their own, which says what part of the gene is missing when the reads are deep enough to tell. A called gene whose reads show a problem carries a check alignment mark, and every gene says how close it is to the nearest allele in the database (more on both in the notes below). Then come the virulence factors by VFDB category. Use Print / save PDF on the results page to keep a copy.

If PointFinder covers your species, the genes are followed by the point mutations found: each one with the antibiotics PointFinder lists for it, its notes, and the CABBAGE rates of isolates with the same mutation, so gyrA p.S83L in E. coli reads like a gene does. A mutation that PointFinder only counts together with another one (parC changes that need a gyrA change, for example) is listed apart when the other one is not there, and so is a mutation that only some of the reads carry. A different change at a codon PointFinder lists is shown too, with its CABBAGE rates when there are any (gyrA S83I in K. pneumoniae, where the table holds S83L and S83F), but not counted. PointFinder marks its whole Klebsiella table as under development, and many of its porin and acrR rows are differences between lineages, so a row marked like that counts only when NCBI's AMRFinderPlus curates the same mutation; the others are listed as use with caution. The section ends by saying how many of the listed positions the reads covered, because a position with no reads is not the same as no mutation. Mutations that are not in PointFinder's table are not reported, and neither are genes that are switched off or made in larger amounts, so a susceptible-looking report can still miss chromosomal resistance.

When the species is known, each gene also shows how often isolates of that species carrying it tested resistant in CABBAGE (Comprehensive Assessment of Bacterial-Based AMR prediction from Genotypes, Dickens et al., NAR 2026). CABBAGE links 170,750 sequenced isolates to 1.7 million susceptibility test results. Genotypes are AMRFinderPlus calls, and phenotypes are reinterpreted with the 2025 CLSI and EUCAST breakpoints. The report reads, for example: In CABBAGE, S. aureus with mecA tested resistant to methicillin in 97.7% of 1,792 isolates.

Rates are shown only for antibiotics the gene is known to affect: those ResFinder lists for it, and those CABBAGE links to it by drug name. Rates for other antibiotics mostly reflect other genes carried by the same lineages, so they are left out. Only rates from at least 20 tested isolates are shown. Each rate is followed by the rate among all sequenced isolates of the species with a test result, because a high rate means little when most of the species is resistant anyway. Phenotypes are read with 2025 breakpoints; the Breakpoints choice in the report header switches between CLSI first (EUCAST where CLSI has no breakpoint) and EUCAST first. CABBAGE covers 28 species. The species is filled in for public runs and the example. For your own files, type it in on the input page or the results page.

These rates describe other isolates, not your sample, and include the effect of any other genes those isolates carry. They are not a susceptibility test, so confirm results that matter for treatment in the laboratory. To explore the full database, use the EMBL-EBI AMR portal. Everything is computed in your browser from a cached snapshot of under 1 MB. The rates behind the report are in the results ZIP as cabbage_predictions.csv.

hAMRonization

Every gene hit is also available in the hAMRonization format of the Public Health Alliance for Genomic Epidemiology (PHA4GE), which many AMR tools share. hAMRonization (TSV) on the results page downloads it for the sample, and the results ZIP holds it as TSV and JSON. The files combine with other tools' hAMRonized results, for example with hamronize summarize. They were checked against the hAMRonization 1.3.1 package, whose own writer produces the same files from these records.

There is one row per called gene and database, as KMA reports it, without the merging of ResFinder and CARD calls the report does; partial genes and hits below the thresholds stay in the KMA output files. A gene whose reads KMA divided between two sister alleles is one row, for the closer of them, with the numbers of all its reads together. input_file_name is the sample name, and the analysis software is openpathogen with its build number. Coverage is template coverage and identity is the identity over the aligned part, the same numbers the gene tables and the sliders use, as in the hAMRonization parser for KMA output. Drug classes, antibiotics and resistance mechanisms come from ResFinder's phenotype table. VFDB has no version number, so its release date (2026-05-01) stands in for it.

PointFinder mutations are written the way hAMRonization writes ResFinder's: one row per gene with its mutations together (p.S83L, p.D87N), as protein_variant_detected, or nucleotide_variant_detected for rRNA and promoter changes (r.2058A>G, n.-42C>T), with the codon changes and PointFinder's notes. Only the mutations counted in the report are written; those in some of the reads only, or without the mutation they need, are not.

Notes

  • KMA runs with the settings ResFinder uses for reads (-e 1.0 -apm p -cge -1t1) and KMA's own default -ID 1, so it reports every gene it puts reads on, and moving the sliders never changes what KMA does. The thresholds are applied afterwards, in the browser, to two independent numbers: identity is measured over the aligned part of the gene (KMA's Query_Identity) and coverage over the gene's full length (Template_Coverage). The defaults are 90% and 90%, which call the genes ResFinder calls: ResFinder filters on identity over the whole gene, which cannot fall below the coverage, so it never reports a gene that is less than 90% covered. openpathogen lists such hits as partial genes instead of dropping them: a hit that reaches the identity threshold but not the coverage threshold, or one whose well-aligned part alone would pass both. Lower the identity threshold to pick up divergent variants, or lower the coverage threshold to call genes that are only partly covered (with short reads, a gene that is all there is less than 90% covered only below about 2× depth, so most hits between 60% and 90% coverage are genes that are cut short). Both sliders apply to every selected database.
  • The reads behind every gene are checked, from KMA's own per-base output (the depth matrix and the alignment in the ZIP). A stretch of a gene with no reads is weighed against the gene's depth: at 60×, a stretch of 238 bases is not missed by chance, so that part of the gene is missing from the sample, or too different to align, and the report says which part. At 3×, gaps like that are what thin coverage leaves, and the gene may well be complete.
  • When the allele in a sample is not in the database, KMA can divide its reads between two sister alleles, and each then looks partly covered. At the positions where the two differ, the reads of one allele show one base and the reads of two alleles show both, so openpathogen tells the cases apart: one allele is shown as one gene, with the reads of both and the closest allele named, and two alleles are both listed, each naming the other. With a redundant database a few reads of every gene also land on its sister alleles; those are counted with the gene and not listed again. Sisters are recognised by their sequence, not their names, so alleles the database files under different names (Serratia's chromosomal AmpC as blaSRT-2 and blaSST-1, or aadA1 inside ant(3'')-Ia, which ResFinder annotates from an upstream start) are read as one gene too.
  • Each gene's consensus is translated in frame. A stop codon or frameshift that most of the reads carry makes a gene partial, since its protein is cut short, unless a start codon just after it gives the whole protein (some alleles in the database start a few codons earlier than others); on Nanopore reads, where a lost base in a run of one base is a common sequencing error, it is a warning instead. When the sample's allele is not an exact match, the report names the closest allele in the database and the number of differences (an allele that is not in the database may act differently). A gene far below the depth of the other genes found gets a note too: it may be in a minority of the cells, or come from contamination (under a twentieth of their depth it is marked check alignment, as such genes mostly turned out to be contamination when checked against complete genomes).
  • A called gene whose reads show a problem is marked check alignment in the report and the tables: a stretch the reads do not reach, a stretch that aligns at under 85% identity over at least a tenth of the gene, a stop codon that only some of the reads carry, or a short stretch where the reads disagree at many positions, where the reads of two different sequences meet (a gene in two partial copies can look whole from the reads). The poorly aligned stretch catches truncated genes that long reads can make look complete: the flanking sequence is aligned across the missing part at low identity, and the consensus still reaches 90% identity over the whole gene. The gene viewer shows where it is.
  • Nanopore mode runs KMA as ResFinder does for Nanopore reads: -bcNano -mp 20 -ont -md 5, which adds indel-aware base calling, the long-read preset and a minimum depth of 5. Without the preset, each long read tends to be assigned to a different allele of the same gene, and the report fills with alleles seen in a single read. fastp then only reports statistics.
  • Point mutations are read from the same per-base counts. The reads are mapped to PointFinder's genes for the species with the same KMA command, and each listed position is read when at least 5 reads cover it (10 for Nanopore) and most of them agree. A gene counts as there when over 80% of it matches, as in ResFinder. The rRNA genes have several near-identical copies (seven 23S copies in E. coli), which KMA divides the reads between, so the copies are read together, and a change that only some of the reads carry is listed with its share. An insertion or deletion is matched by the sequence it makes, so it is found wherever the reads place it in a repeat. A position the reads do not reach is reported as not read (ResFinder reads it as a deletion). The ZIP has every position as read in pointfinder_positions.tsv.
  • Each PointFinder row is checked against its gene before it is used, and a few are corrected (a template name typo, three positions written in E. coli numbering). PointFinder's Klebsiella gyrA and parC turned out to be E. coli genes under K. pneumoniae accession numbers: K. pneumoniae reads match them at about 65%, below the 80% a gene needs, so the most common quinolone mutations of K. pneumoniae could never be read. openpathogen reads them on the genes of the K. pneumoniae type strain (ATCC 13883) instead, which have the same residue at every listed position. For the same reason, K. oxytoca and K. aerogenes are not read with the Klebsiella table: their genes are 79 to 89% identical to it. Where a gene has a template per species (Campylobacter gyrA), the one the reads match is read.
  • All of this was checked against 34 sequenced isolates of 32 species with genome assemblies in NCBI, most of them complete, run through openpathogen at 40× of their reads. 119 of the 120 intact genes in the genomes were called (the one missed is a second, nearly identical SHV allele, which reads alone cannot separate), the allele was named right for 114 of 116, and duplicate calls fell from 33 to 1. Of the calls with no gene in the genome, all but two are plasmid genes at 60 to 860× that the assemblies left out; the two, at under 2×, were contamination, and the report marks them. PointFinder's mutations agreed with NCBI's AMRFinderPlus run on the same genomes wherever PointFinder's table holds the mutation.
  • Click any gene name in the report or the gene tables to see its coverage, consensus sequence, alignment and variants.
  • Print / save PDF prints the report with every gene table expanded. In the print dialog, choose "Save as PDF" to keep a file.
  • The results ZIP contains, per database, .res, .aln, .fsa, .frag.gz, .mat.gz, .vcf.gz and .mapstat, plus the hAMRonization report (hamronized_report.tsv and .json), the PointFinder mutations and positions (pointfinder_results.tsv, pointfinder_positions.tsv), the fastp reports, Deacon's deacon_summary.json, the CABBAGE table as CSV and the run log.
  • openpathogen needs a browser with SharedArrayBuffer support: recent Chrome, Firefox, Edge or Safari, on a computer or a phone. Chrome, Edge and Firefox run the 64-bit engine, which can use more than 4 GB of memory. Safari and every browser on iPhone and iPad run a 32-bit build of the same tools, which gives the same results but has at most 4 GB of memory, and much less on a phone. On a phone, keep inputs small (the example, or a few hundred MB) and keep the page open and the screen on until the run finishes.

Citation

A short communication is in preparation. Until then, cite KMA, fastp, CABBAGE, Deacon if you removed human reads, and the databases you used:

Clausen PTLC, Aarestrup FM, Lund O. Rapid and precise alignment of raw reads against redundant databases with KMA. BMC Bioinformatics. 2018;19:307. doi:10.1186/s12859-018-2336-6

Chen S, Zhou Y, Chen Y, Gu J. fastp: an ultra-fast all-in-one FASTQ preprocessor. Bioinformatics. 2018;34(17):i884–i890. doi:10.1093/bioinformatics/bty560

Dickens E, et al. A comprehensive AMR genotype–phenotype database (CABBAGE). Nucleic Acids Research. 2026. doi:10.1093/nar/gkag780. Data CC-BY 4.0.

Constantinides B, Lees J, Crook DW. Deacon: fast sequence filtering and contaminant depletion. bioRxiv. 2025. doi:10.1101/2025.06.09.658732

Zankari E, Allesøe R, Joensen KG, Cavaco LM, Lund O, Aarestrup FM. PointFinder: a novel web tool for WGS-based detection of antimicrobial resistance associated with chromosomal point mutations in bacterial pathogens. J Antimicrob Chemother. 2017;72(10):2764–2768. doi:10.1093/jac/dkx217

Database citations (ResFinder, CARD, VFDB) and component licenses are listed in THIRD_PARTY_NOTICES.