Reverse complement generator
v1.0.0Generate reverse, complement, or reverse-complement sequences from raw, FASTA, or FASTQ DNA and RNA input.
Paste a DNA or RNA sequence, or upload a FASTA or FASTQ file containing one or more records. Select the matching sequence type, choose Reverse complement, and run the conversion. ProteinIQ writes the opposite strand in the 5' to 3' direction and returns a result that can be copied or downloaded. The conversion runs in the browser.
With the default settings, this DNA sequence:
>BRCA1_fragment
TTAGCTGATGTATTGCTTTGreturns:
>BRCA1_fragment_reverse_complement
CAAAGCAATACATCAGCTAATo convert a sequence:
.txt, .fasta, .fa, .fas, .seq, .fastq, or .fq file. Word (.docx) and text-based PDF files can also supply sequence text.Sequence type on Auto-detect, or select DNA or RNA to require one alphabet.Operation set to Reverse complement, or choose another transformation.No account or credits are required. Uploaded files may contain up to 50 MB of sequence data. Because All operations creates three complete outputs, that operation accepts up to 16.7 MB of input so the generated sequence data stays within the 50 MB conversion output budget.
Write the partner strand under 5'-ATGCAGTC-3' base by base and the three operations fall out of the picture:
5'-ATGCAGTC-3' input
3'-TACGTCAG-5' complement
5'-GACTGCAT-3' reverse complementThe complement swaps every base for its pairing partner, A with T and C with G, and keeps the original order. That gives the partner strand, but written 3' to 5', which is not how sequences are stored, reported, or ordered from a synthesis company. Reading the same strand from its 5' end gives the reverse complement, the form a database or primer order expects.
Reverse alone flips the order without pairing anything. CTGACGTA is not a strand that exists in the duplex, so it rarely answers a lab question by itself. It is useful for checking orientation conventions, or for undoing a reversal made elsewhere.
| Goal | Operation | Result for ATGCAGTC |
|---|---|---|
| Write the opposite strand from 5' to 3' | Reverse complement | GACTGCAT |
| Read the same sequence from right to left | Reverse only | CTGACGTA |
| Replace each base with its partner without changing order | Complement only | TACGTCAG |
| Inspect all three transformations | All operations | All three results above, as separate records or lines |
RNA follows the same rules with U in place of T, so the reverse complement of AUGC is GCAU. Complementing and reversing can happen in either order because each base is transformed independently; only the final 5' to 3' orientation matters. Changing T to U without pairing is transcription, not complementation, and belongs in DNA to RNA.
For 5'-ATGCAGTC-3', the reverse complement is 5'-GACTGCAT-3'. With the default FASTA output setting, raw input receives a FASTA header:
>seq_reverse_complement
GACTGCATChoose Same as input or Plain text when a headerless raw-sequence result is preferred.
Auto-detect recognizes this as RNA because it contains uracil. This input also includes IUPAC ambiguity codes:
>rna_oligo
AUGCRYSWKMBDHVNThe exact output is:
>rna_oligo_reverse_complement
NBDHVKMWSRYGCAURNA output uses U, not T. Selecting DNA explicitly for this record would report U as invalid.
All operations returns reverse, complement, and reverse complement in that order. With Preserve original case enabled, this input:
>mixed_case_region description
AtGcRynNreturns:
>mixed_case_region_reverse description
NnyRcGtA
>mixed_case_region_complement description
TaCgYrnN
>mixed_case_region_reverse_complement description
NnrYgCaTThe suffix is added to the record identifier. Any description after the first space stays unchanged.
FASTQ output keeps one quality character aligned with each nucleotide. This input has distinct quality characters so their movement is visible:
@read1 description
AtGC
+read1 description
!#5IWith Output format set to Same as input and lowercase output selected, the reverse complement is:
@read1_reverse_complement description
gcat
+read1_reverse_complement description
I5#!The sequence and quality string are both reversed, while only the sequence is complemented. If the + line repeats the read header, its operation suffix is updated too.
Set Start a new sequence to At each non-empty line to transform these as two separate sequences:
ATGC
GCTAWith the other defaults unchanged, the output is:
>seq_1_reverse_complement
GCAT
>seq_2_reverse_complement
TAGCLeave the boundary setting on Detect from input format when those lines are parts of one wrapped sequence. That produces one record containing TAGCGCAT.
The IUPAC nucleotide codes represent sets of possible bases. The complement is the code representing the paired set, not automatically N, so a degenerate primer keeps exactly the same coverage on the other strand. DNA and RNA transformations follow the pairing rules illustrated in the Biopython sequence reference.
Two-base codes swap in pairs: R (A or G) with Y, and K with M. Three-base codes swap the same way, B with V and D with H. S, W, and N are their own complements because each set already contains both partners; in a reverse complement they keep their letter and only move to the mirrored position.
| Code | Bases represented | Complement |
|---|---|---|
A | A | T in DNA, U in RNA |
T | T | A |
U | U | A |
C | C | G |
G | G | C |
R | A or G | Y |
Y | C or T/U | R |
S | G or C | S |
W | A or T/U | W |
K | G or T/U | M |
M | A or C | K |
B | C, G, or T/U | V |
D | A, G, or T/U | H |
H | A, C, or T/U | D |
V | A, C, or G | B |
N | Any base | N |
- or . | Alignment gap | Unchanged |
PCR is the most common reason. Both primers are written and ordered 5' to 3', but the reverse primer anneals to the top strand, so its sequence is the reverse complement of the region it targets. The universal bacterial 16S rRNA primers show this. The forward primer 27F can be found in the gene as written, while the reverse primer 1492R appears only as its reverse complement:
>27F
AGAGTTTGATCMTGGCTCAG
>1492R
GGTTACCTTGTTACGACTTWith the default settings, the output is:
>27F_reverse_complement
CTGAGCCAKGATCAAACTCT
>1492R_reverse_complement
AAGTCGTAACAAGGTAACCAAGTCGTAACAAGGTAACC is the conserved stretch near the 3' end of the 16S gene that 1492R binds, so searching a 16S sequence for it locates the primer site. The degenerate M in 27F becomes K, which keeps both template variants covered on the other strand. Primer3 already reports reverse primers 5' to 3'; this conversion is for going the other way, from a published primer back to the strand you are reading.
Genes sit on both strands, but reference FASTA files and genome browsers show only the plus strand. Human TP53 and BRCA1 both lie on the minus strand of chromosome 17, so a region copied from the reference reads as the reverse complement of their mRNA. Reverse-complementing it gives the sense sequence for DNA to protein. A BLAST hit marked Plus/Minus means the same thing: the query matched the subject's other strand.
Sequencing produces reads from both strands. In paired-end Illumina data, read 2 comes from the opposite strand of the fragment, so overlapping pairs only line up after read 2 is reverse-complemented; FASTQ mode keeps every quality score with its base. A Sanger read primed from the reverse primer needs the same step before it can be aligned with the forward read.
Short sequences that equal their own reverse complement are palindromic. The EcoRI site GAATTC returns GAATTC, which is why the enzyme recognizes both strands at the same place. A primer in which one stretch matches the reverse complement of another can fold into a hairpin, which the Oligo analyzer scores.
Antisense oligonucleotides, siRNA guide strands, and hybridization probes bind their target by base pairing, so each is designed as the reverse complement of the target RNA. Auto-detect keeps the input alphabet, so an mRNA target written with U returns a U-containing guide, and a DNA target returns a DNA probe.
| Input method | Accepted input | Limit and behavior |
|---|---|---|
| Paste | Raw DNA or RNA, FASTA, or FASTQ | Spaces and tabs inside raw or FASTA sequences are removed before conversion. By default, line breaks stay within a raw sequence; change Start a new sequence to split on lines or empty lines. FASTQ structure is validated. |
| Upload | .txt, .fasta, .fa, .fas, .seq, .fastq, or .fq | Maximum file size is 50 MB (52,428,800 bytes). |
| Document upload | .docx or .pdf containing selectable text | Sequence text is extracted before conversion. Image-only scans need text extraction elsewhere first. The same 50 MB file limit applies. |
| Batch FASTA | One or more records beginning with > headers | Records are processed in their original order. Each record is validated independently. |
| Batch FASTQ | One or more records beginning with @ headers | Wrapped sequence and quality sections are accepted. Sequence and quality lengths must match. |
For plain-text batches, choose At each non-empty line when every pasted line is one sequence, or After an empty line when a wrapped sequence should continue until a blank line. Choose At FASTA headers only when only > headers should create records. FASTA and FASTQ input always use their native record structure.
Sequence letters are case-insensitive during validation. DNA mode accepts A, T, C, G, all supported IUPAC ambiguity codes, -, and .. RNA mode accepts the same set with U in place of T.
Auto-detection runs independently for each raw, FASTA, or FASTQ record:
U but no T is RNA.T but no U is DNA.T nor U defaults to DNA because the alphabet cannot be inferred. Select RNA explicitly when such a sequence should complement A to U.T and U is rejected and named in a warning.This allows one FASTA batch to contain separate DNA and RNA records without applying the wrong complement alphabet to either record.
Raw and FASTA sequence bodies accept pasted document formatting: invisible spaces, soft hyphens, leading list bullets, and typographic gap dashes are normalized. Spaces, tabs, and line breaks are removed within each record. Lines beginning with # are comments in raw text and FASTA. Headers retain their identifiers and descriptions.
Recognized position numbers in raw sequence displays are removed only when they agree with the nucleotide positions. For example, 1 atgc 4 is read as atgc; AT1GC remains invalid. Numbers inside FASTA sequence bodies, other punctuation, and non-nucleotide letters are rejected. Use GenBank to FASTA for complete GenBank records, CSV to FASTA for CSV columns, or TXT to FASTA for named or tabular text.
Plain text must contain sequence data only. Put names on separate FASTA header lines beginning with >, even when a name consists entirely of IUPAC letters. Such a name cannot be distinguished from sequence data. Invalid, empty, or unnamed FASTA records are skipped with warnings. If every record is invalid, no sequence file is returned.
FASTQ quality characters are not interpreted as nucleotide text. They must be printable Phred+33 ASCII characters, with exactly one character for each nucleotide. A malformed FASTQ file, including a record with invalid nucleotide symbols, fails validation rather than returning a partial file.
| Setting | Options | Default | What it controls |
|---|---|---|---|
Sequence type | Auto-detect, DNA (A, T, C, G), RNA (A, U, C, G) | Auto-detect | Detects DNA or RNA independently for each record, or requires the selected alphabet. |
Operation | Reverse complement, Reverse only, Complement only, All operations | Reverse complement | Chooses which transformation is returned. All operations creates three outputs per valid input record and accepts up to 16.7 MB of input. |
Start a new sequence | Detect from input format, At each non-empty line, After an empty line, At FASTA headers only | Detect from input format | Controls plain-text record boundaries. FASTA headers and FASTQ records always retain their native boundaries. |
Output case | Uppercase (ATCG), Lowercase (atcg), Preserve original case | Uppercase (ATCG) | Changes sequence letters only. FASTA and FASTQ header capitalization is not changed. |
Output format | Same as input, FASTA, Plain text | FASTA | Returns FASTA by default; keeps raw text, FASTA, or FASTQ input in its original format when selected; or returns sequence-only text. |
FASTA line wrapping | No wrapping (single line), 60 characters per line, 80 characters per line (standard) | 80 characters per line (standard) | Controls FASTA sequence line width. It does not change FASTQ or plain-text output. |
Add operation suffix to headers | On or off | On | Adds _reverse, _complement, or _reverse_complement to each FASTA or FASTQ identifier. It has no visible effect with plain-text output. |
The defaults auto-detect each record and produce an uppercase reverse complement in FASTA format. Raw input receives a generated FASTA header, and FASTQ quality scores are omitted with a warning. Select Same as input when FASTQ output and aligned quality scores should be preserved. The _reverse_complement suffix is added when the selected output format includes identifiers.
| Result | What it contains |
|---|---|
| Preview | The converted output, with a copy action and a summary of converted records, nucleotide length, and skipped records. |
| FASTA download | Returned when Output format is FASTA, or when FASTA input uses Same as input. The selected line wrapping is applied. |
| FASTQ download | Returned when FASTQ input uses Same as input. It contains transformed reads and aligned quality strings. |
| Text download | Returned when Output format is Plain text, or when raw input uses Same as input. It contains sequences without headers or FASTQ quality lines. |
| Warnings | The header and invalid characters for any skipped batch record. Valid records are still returned. |
Logs and run.log | Conversion counts, formats, operation, input GC percentage, cleanup counts, and warning count. The log contains no sequence text or header descriptions. Failed conversions also return a short diagnostic log. |
Plain-text output contains one sequence line for each valid input record. All operations produces three lines per record in reverse, complement, and reverse-complement order. FASTQ quality scores are omitted from FASTA or plain-text output, and the result includes a warning so the loss is explicit.
FASTA wrapping changes only where line breaks appear. It does not alter sequence length or content. Choose 80 characters for the conventional default, 60 characters for tools or reports that expect shorter lines, or no wrapping to place each sequence on one line. FASTQ remains one sequence line plus one matching quality line per output record.
Each FASTA record is cleaned, validated, and transformed separately. This makes partial success possible. For example:
>valid_dna
ATGCRY
>invalid_dna
AUGCIn DNA mode, the first record returns:
>valid_dna_reverse_complement
RYGCATThe second record is skipped with the warning Skipped >invalid_dna: invalid DNA characters U.
When suffixes are enabled, they are inserted before a FASTA description. A header such as >sample human exon becomes >sample_reverse_complement human exon. Duplicate identifiers are preserved and reported in warnings. Supply unique names if downstream software requires them. Empty records and headers without an identifier are skipped and named in warnings.
FASTQ stores a quality character for each sequence position. Reverse-complementing a read changes the position of every nucleotide, so its quality characters must move to the matching reversed positions.
| Operation | Sequence action | Quality string action |
|---|---|---|
Reverse complement | Reverse the sequence and complement every base | Reverse |
Reverse only | Reverse the sequence | Reverse |
Complement only | Complement every base without changing position | Keep original order |
All operations | Return all three sequence transformations | Reverse for _reverse and _reverse_complement; keep order for _complement |
Quality values are preserved exactly. The tool does not recalculate, normalize, filter, or trim them. Wrapped FASTQ sequence and quality sections are joined during parsing, then written as one sequence line and one quality line per output record.
FASTQ record order and header descriptions are preserved. An empty + line remains empty. If the + line repeats the original header, the same _reverse, _complement, or _reverse_complement suffix is applied so it continues to match the transformed read identifier.
A nonempty + line must have the same read identifier as its @ header. A repeated identifier alone is accepted even when the header has a description. A different identifier fails the conversion. Pasted document cleanup is never applied to FASTQ quality strings; invisible or non-ASCII quality characters are rejected.
Uppercase and lowercase output modes normalize only sequence lines. FASTA headers retain their original case.
Preserve original case carries the case of each nucleotide through the transformation. Because reverse and reverse-complement operations change position, the capitalization moves with its nucleotide. For example:
| Input | Operation | Preserved-case output |
|---|---|---|
AtCg | Reverse | gCtA |
AtCg | Complement | TaGc |
AtCg | Reverse complement | cGaT |
Gap characters - and . are accepted and kept in place for complement-only output. They move with the sequence during reverse and reverse-complement operations. They are useful for aligned sequences, but the tool does not calculate or modify an alignment.
The run log records GC percentage across valid input records. Only canonical bases contribute to this calculation:
IUPAC ambiguity codes, -, and . are excluded from both the numerator and denominator. The percentage describes the submitted sequence, not the expanded number of records created by All operations.
U is invalidChange Sequence type to RNA if the input uses uracil. DNA mode deliberately rejects U so a DNA/RNA alphabet mismatch is not converted silently.
T is invalidChange Sequence type to DNA if the input uses thymine. RNA mode deliberately rejects T.
Read the warning for the record header and invalid characters. Remove numbers, unsupported punctuation, or non-nucleotide letters, then convert again. Other valid records in the same batch are still returned.
Each FASTQ record needs exactly one quality character per nucleotide. Check for truncated quality lines, accidental line breaks, or a missing + separator. Wrapped records are accepted, so wrapping itself does not cause an error when the joined lengths match.
Set Output format to Same as input or FASTA. Plain-text output intentionally removes FASTA and FASTQ headers, plus FASTQ quality and separator lines. FASTA output from FASTQ also omits quality scores and reports a warning.
_reverse_complement, _reverse, or _complementThese suffixes identify the operation that produced each record. Turn off Add operation suffix to headers to retain the original identifier unchanged.
Replace A with T, T with A, C with G, and G with C, then reverse the result. For example, the reverse complement of ATCG is CGAT.
Leave auto-detection enabled or select RNA explicitly, then submit a sequence containing A, U, C, and G, with optional IUPAC ambiguity codes. RNA output uses U, so the reverse complement of AUGC is GCAU.
No. Complement changes each base but keeps the written order. Reverse complement also reverses that result so the paired strand is written in the conventional 5' to 3' direction.
No. Reverse transcription is the enzymatic copy of RNA into cDNA. Its first strand is the reverse complement of the RNA written with T, but cDNA sequences in databases are usually reported in the mRNA sense, so turning an mRNA sequence into its cDNA notation only replaces U with T. Use RNA to DNA for that letter change.
In Biopython, Seq("ATGCAGTC").reverse_complement() returns Seq('GACTGCAT'). For FASTA or FASTQ files, seqkit seq -r -p input.fasta reverses and complements every record. The browser tool gives the same result without installing anything and reports skipped records by name.
Yes. Paste or upload multi-record FASTA. Valid records are returned in their original order, while invalid records are skipped and identified in warnings.
Yes. Upload .fastq or .fq input and set Output format to Same as input. Reverse and reverse-complement operations reverse the quality string so each score stays aligned with its original base; complement-only output keeps quality characters in their original order.
No. Quality characters move with their nucleotide positions but are not recalculated. Their encoded quality values remain unchanged.
Yes. The converter supports R, Y, S, W, K, M, B, D, H, V, and N, including lowercase forms. It also preserves - and . gap characters.
Yes. Select Preserve original case to carry each character's capitalization through the operation, or select Lowercase to normalize every output sequence letter.
No compute server performs the sequence transformation. Conversion runs locally in the browser. Normal website requests still occur when the ProteinIQ page loads.
Extract CDS, mRNA, gene, rRNA, and tRNA features from GenBank records into FASTA.
Convert FASTA sequences to FASTQ with configurable mock Phred quality scores.
Convert FASTQ sequencing reads to FASTA while preserving headers and sequence case by default.
Convert CSV or TSV sequence tables to FASTA with automatic delimiter detection and column mapping.
Paste or upload a sequence file in any common format and download FASTA. The format is detected automatically, and nothing leaves your browser.
Convert GenBank records to FASTA by extracting primary sequences, CDS, or translations.
Paste or upload DNA, RNA, or protein text and download FASTA. Sequence names, wrapped lines, and tables are detected automatically, and nothing leaves your browser.
Convert coding-strand DNA to RNA notation by replacing thymine with uracil.
Replace U with T while keeping the same strand orientation. Paste RNA or upload a sequence file.
Paste or upload FASTA and download a CSV or TSV table for spreadsheets, or a plain text file with one sequence per line.