LabCanvas
Free account · save your work, full figure editorSign up free

Primer Tm calculator (nearest-neighbour, with salt and Mg²⁺)

Paste one or two primers (5′→3′) and the calculator gives each primer’s melting temperature from the SantaLucia 1998 nearest-neighbour parameters, corrected for your oligo concentration, Na⁺/K⁺, Mg²⁺ and dNTPs, with the Tm difference between the primers, GC content, molar mass, ΔH°, ΔS°, the G/C count at the 3′ end and the longest repeats.

What it does
Calculates primer melting temperature with SantaLucia 1998 nearest-neighbour parameters, corrected for oligo, Na⁺/K⁺, Mg²⁺ and dNTP concentrations, plus GC %, ΔG and pair ΔTm.
Formula
Tm=ΔH∘÷(ΔS∘+Rln⁡(CT/F))−273.15ΔS∘+=0.368×(N−1)×ln⁡[Na+]eq[Na+]eq=[Na+]+[K+]+[Tris]/2+3.79[Mg2+]−[dNTP]
Example
AGCGGATAACAATTTCACACAGGA at 250 nM in 50 mM K⁺, 1.5 mM Mg²⁺, 0.8 mM dNTP: Tm = 184,400 ÷ (516.74 + 30.21) − 273.15 = 64.0 °C.

Last updated

FreeNo sign-upRuns in your browserLab calculators

Loading Primer Tm calculator…

At a glance

Primer Tm calculator at a glance
ModelTwo-state nearest-neighbour, SantaLucia 1998 unified parameters
Salt correctionΔS∘+0.368(N−1) ln⁡[Na+]eq, as implemented in Primer3; Mg²⁺ and Tris as sodium equivalent
StrandsPrimer in excess (CT) or equal strands (CT/4); self-complementary detected
Also givesGC %, molar mass, ΔH∘, ΔS∘, ΔG37∘, 3′ G/C count, repeats, reverse complement
Not includedMismatches, mixed bases, modifications, DMSO, formamide
Runs inYour web browser; nothing is uploaded
PriceFree, no account needed

What it does

How to use the primer Tm calculator

  1. Paste the primersEnter one or two primers 5′→3′. Spaces, numbers and FASTA headers are ignored; only A, C, G and T are accepted.
  2. Set the reactionEnter the primer concentration (nM) and the Na⁺ + K⁺, Mg²⁺, total dNTP and Tris concentrations of your buffer (mM).
  3. Choose the strand settingLeave “Primer in excess (PCR)” for PCR primers; choose “Equal strands” for two complementary oligos mixed at equal concentration.
  4. Read the resultRead each Tm and the difference between the two primers, then check GC content, the 3′ end and repeats.
  5. Save itCopy the result with its conditions, or download the CSV.

How it works

Tm=ΔH∘ΔS∘+Rln⁡(CT/F)−273.15

The duplex is treated as melting in two states. ΔH∘ and ΔS∘ are the sums of the ten nearest-neighbour stacks of the unified DNA parameters (SantaLucia 1998, PNAS 95:1460; the table as printed in Wang et al. 2025, PLoS One), plus an initiation term for each end (terminal G·C: ΔH∘ 0.1 kcal/mol, ΔS∘ −2.8 cal/(K·mol); terminal A·T: 2.3 and 4.1) and, for a self-complementary sequence, a symmetry term of −1.4 cal/(K·mol). R=1.987 cal/(K⋅mol). CT is the total strand concentration; F=1 when one strand is in large excess (a PCR primer over its template) or the strand is self-complementary, and F=4 for two strands at equal concentration (MELTING 5, Dumousseau et al. 2012).

ΔS∘[Na+]=ΔS∘(1 M)+0.368×(N−1)×ln⁡[Na+]eqeq=[Na+]+[K+]+[Tris+]/2+3.79[Mg2+]−[dNTP]

The salt correction is the entropy term as implemented in Primer3 (and Biopython), which attribute it to SantaLucia (1998); we could not read the constant in the paper itself. N is the primer length and concentrations are in mol/L. Mg²⁺ and Tris are converted to a sodium equivalent with the von Ahsen formula (as given in MELTING 5); dNTPs bind Mg²⁺, so only Mg²⁺ above the dNTP concentration counts. This combination is the one von Ahsen et al. (Brief Bioinform 2011) recommend when Mg²⁺ is present, and with CT/4 it gives the same Tm, to within 0.01 °C, as Primer3’s SantaLucia setting.

Molar mass is for the free acid with 5′-OH and 3′-OH ends, from the elemental formulas of the nucleotides and the CIAAW 2021 atomic weights. The model is for a perfectly matched DNA/DNA duplex: mismatches, mixed bases, modifications, DMSO and formamide are not included.

Worked example

Primer 5′-AGCGGATAACAATTTCACACAGGA-3′ (24 nt), 250 nM, 50 mM K⁺, 1.5 mM Mg²⁺, 0.8 mM dNTP, primer in excess.

Summing the 23 stacks and the two terminal initiation terms gives ΔH∘=−184.4 kcal/mol and ΔS∘=−500.7 cal/(K⋅mol) in 1 M NaCl. The sodium equivalent is 0.050+3.79×0.0015−0.0008 =0.1503 M, so the salt term is 0.368×23×ln⁡0.1503=−16.04 and ΔS∘=−516.74. With Rln⁡CT=1.987×ln⁡(2.5×10−7) =−30.21:

Tm=184400516.74+30.21−273.15=64.0 ∘C

With equal strands (CT/4) the same primer gives 62.3 °C; in 50 mM Na⁺ with no Mg²⁺, 56.7 °C.

Frequently asked questions

How is the Tm of a primer calculated?

With the nearest-neighbour model: the enthalpy and entropy of the duplex are added up from each pair of neighbouring base pairs (SantaLucia 1998 parameters), and Tm=ΔH∘/(ΔS∘+Rln⁡(CT/F))−273.15, after correcting ΔS∘ for the salt in the buffer.

Why does the Tm depend on the primer concentration?

Duplex formation is a two-strand equilibrium, so the concentration enters the Tm equation through Rln⁡(CT/F): more primer gives a higher Tm.

How do Mg²⁺ and dNTPs change the Tm?

Mg²⁺ stabilises the duplex and raises the Tm. dNTPs bind Mg²⁺, so only the Mg²⁺ above the dNTP concentration is counted; it is converted to a sodium equivalent of 3.79×[Mg2+]−[dNTP] mol/L.

Why does another calculator give a different Tm?

Calculators differ in their nearest-neighbour parameters, salt corrections and strand-concentration convention (CT or CT/4). For example, Primer3 uses CT/4; choose “Equal strands” here to compare. Check that the concentrations entered match.

What annealing temperature should I use?

This tool gives the Tm, not an annealing temperature. The optimal annealing temperature depends on the Tm of the less stable primer–template pair and of the product (Rychlik et al. 1990), so it is best confirmed experimentally, for example with a temperature gradient.

Does it handle mismatches, mixed bases or modified oligos?

No. It calculates the Tm of a perfectly matched DNA/DNA duplex from A, C, G and T only.

What is a self-complementary primer?

A sequence that is its own reverse complement, such as GCGCGCGCGC. It can pair with itself, so the calculator adds the symmetry correction and uses CT rather than CT/4.

Make the whole figure in LabCanvas

Vector figure editor, slides, 3D models, protein structures and Prism-style graphs, in your browser.

Get started