Reverse complement of DNA and RNA
Sequence direction and strand orientation
DNA/RNA sequences are written by convention from 5′ to 3′. In double-stranded DNA, the two strands are antiparallel, so the “same” region can be represented in two different orientations depending on which strand you read. Reverse complementation puts sequence content from the opposite strand into the same 5′→3′ frame for comparison and downstream use.
Top strand (5′→3′): 5′ A C G T A G C 3′
| | | | | | |
Bottom strand (3′→5′): 3′ T G C A T C G 5′
Read bottom strand 5′→3′ (reverse complement of top):
5′ G C T A C G T 3′What is a reverse complement?
The reverse complement of a DNA or RNA sequence is the sequence you would read on the opposite strand, expressed in the standard 5′→3′ direction. Practically, it is produced by swapping bases to their complements and then reversing the resulting string so the output is still written 5′→3′.
Related sequence operations
- Complement: substitute each base using the chosen alphabet (DNA or RNA), keeping the original order.
- Reverse: reverse the order of characters without changing bases.
- Reverse complement:complement and reverse the sequence (the order of these two operations does not affect the final result), so the output is reported 5′→3′.
Examples
DNA example:
RNA example:
Ambiguous nucleotide symbols
Many datasets include IUPAC ambiguity codes. Reverse complementation can be defined consistently for these symbols as well by complementing the underlying set of bases.
- R (A/G) ↔ Y (C/T in DNA; C/U in RNA)
- K (G/T in DNA; G/U in RNA ) ↔ M (A/C)
- W (A/T in DNA; A/U in RNA) ↔ W
- N ↔ N
Common bioinformatics use cases
- Primer and probe design: writing the sequence that binds to the opposite strand.
- Minus-strand features: inspecting genes or motifs reported on the reverse strand in annotations.
- Comparative work: matching sequences across references where strand choice differs.
- Verification: reconciling sequences copied from reports, viewers, or alignment outputs.