SafFire is an interactive, browser-based visualization tool for genome-to-genome comparisons using miropeats-style ribbon plots. It renders synteny, inversions, and structural rearrangements as colored ribbons between target and query sequences, with support for BED9 annotation overlays and UCSC Genome Browser integration.
Live demo: https://vollgerlab.com/SafFire/
- Miropeats-style ribbons: Forward alignments in blue, inversions in orange, with opacity encoding percent identity
- Interactive navigation: Zoom and pan along the target axis; click coordinates to copy genomic positions
- BED9 annotation overlay: Load custom annotations for both target and query sequences (genes, centromere satellites, segmental duplications, etc.)
- UCSC Genome Browser integration: Synchronize a UCSC browser snapshot to the current viewport
- SVG export: Download publication-quality vector graphics
- URL-based sharing: Bookmark and share specific views via URL hash parameters
- Pre-loaded datasets: Includes T2T-CHM13, GRCh38, and HPRC assemblies
- Zero install: Runs entirely in the browser---no server or software installation required
SafFire takes processed PAF alignments as input. Use minimap2 and rustybam to generate the input:
# Install rustybam
mamba install -c bioconda rustybam
# Align and process
minimap2 --eqx -c -x asm5 reference.fa query.fa \
| rb trim-paf \
| rb break-paf --max-size 5000 \
| rb orient \
| rb filter --paired-len 100000 \
| rb stats --paf \
> input.bedOption A: Upload to the hosted instance at vollgerlab.com/SafFire using the "Load alignment data" button.
Option B: Load via URL parameter:
https://vollgerlab.com/SafFire/#url=https://your-server.com/input.bed
Upload BED9 files using the "Load bed9 data" buttons for target and/or query sequences.
SafFire exposes a URL hash API that lets you link directly to specific views, load remote data, and even trigger automated SVG export. All parameters go after # as key=value pairs joined by &.
Base URL: https://vollgerlab.com/SafFire/#
| Parameter | Description | Example |
|---|---|---|
dataset |
Select a pre-loaded dataset by name | dataset=default |
ref |
Target (reference) genome name | ref=CHM13_v1.1 |
query |
Query genome name | query=GRCh38 |
url |
Load alignment data from a remote URL (TSV) | url=https://example.com/input.bed |
pos |
Navigate to a genomic position; animates a zoom to the region | pos=chr1:1000000-2000000 |
max_bed_items |
Maximum number of BED annotations to render (default: 500) | max_bed_items=1000 |
save |
Auto-download an SVG after navigating to pos (any value) |
save=true |
view |
Open the SVG in the browser after navigating to pos (any value) |
view=true |
Link to a specific region:
https://vollgerlab.com/SafFire/#dataset=default&ref=CHM13_v1.1&query=GRCh38&pos=chr8:1-50000000
Load remote data via URL (any CORS-enabled server or raw GitHub URL):
https://vollgerlab.com/SafFire/#url=https://raw.githubusercontent.com/vollgerlab/SafFire/main/datasets/alignment-tables/GRCh38_to_CHM13_v1.1.tbl
Auto-export an SVG of a region (useful for scripting):
https://vollgerlab.com/SafFire/#dataset=default&ref=CHM13_v1.1&query=GRCh38&pos=chr1:120000000-150000000&save=true
Combine parameters freely:
https://vollgerlab.com/SafFire/#dataset=HPRC&ref=CHM13_v1.1&query=GRCh38&pos=chr22:1-51304566&max_bed_items=200
Note: The
urlparameter can be used standalone (withoutdataset/ref/query). The data file must be a TSV withrb stats --pafoutput columns and served with CORS headers (Access-Control-Allow-Origin: *). Raw GitHub URLs (raw.githubusercontent.com) work out of the box.
SafFire is a static site that can be hosted anywhere:
git clone https://github.com/vollgerlab/SafFire.git
cd SafFire
# Serve with any HTTP server, e.g.:
python3 -m http.server 8000
# Then visit http://localhost:8000To add your own datasets, create entries in datasets/metadata.csv and add the corresponding alignment and BED files to the datasets/ directory.
SafFire requires a modern browser with SVG and ES6 support:
- Chrome 74+
- Firefox 79+
- Safari 14.1+
- Edge 79+
Performance is best with fewer than 100,000 alignment records. Use rb filter and rb break-paf to reduce record counts for large genomes.
If you use SafFire in your research, please cite:
Vollger MR et al. (2026) rustybam and SafFire: a toolkit for CIGAR-aware alignment manipulation and interactive genome comparison visualization. Bioinformatics. (in preparation)
- rustybam --- the CIGAR-aware alignment manipulation toolkit used to prepare SafFire input
- StainedGlass --- identity heatmaps for genome assemblies
MIT