Punnett Square Calculator: Genetic Cross Predictor
Free Punnett square calculator that predicts genotype and phenotype ratios for monohybrid and dihybrid crosses, for genetics homework and breeding plans.
Punnett Square Calculator
Predict genotype and phenotype ratios for genetic crosses. Calculate monohybrid and dihybrid inheritance patterns instantly.
Enter parent genotypes using standard notation (e.g., Aa for monohybrid, AaBb for dihybrid crosses).
Examples:
Punnett Square
| Parent gametes | A | a |
|---|---|---|
| A | AA A | Aa A |
| a | Aa A | aa a |
Phenotype Ratio
A: 3/4, a: 1/4
Understanding Punnett Squares
A Punnett square is a diagram that helps predict the probability of different genotypes in offspring.
Capital letters represent dominant alleles, while lowercase letters represent recessive alleles.
The phenotype is the physical expression of the genotype. A dominant allele will mask a recessive allele in the phenotype.
Documentation
What is a Punnett square?
A Punnett square is a grid used to predict the genetic makeup of offspring from two parents. It was introduced in 1905 by the British geneticist Reginald Punnett to teach Mendel's laws of inheritance. A Punnett square calculator does the same job automatically: enter each parent's genotype, and it lists every possible offspring genotype and phenotype along with the probability of each.
The tool below handles two kinds of crosses. A monohybrid cross tracks one gene, such as flower color (input example: Aa). A dihybrid cross tracks two genes at once, such as seed shape and seed color (input example: AaBb).
Key terms
- Genotype: an organism's genetic makeup, written as a letter pair such as
AaorBB. - Phenotype: the observable trait produced by a genotype, such as a plant being tall or short.
- Allele: one version of a gene. A dominant allele is written with an uppercase letter (
A); a recessive allele is written with a lowercase letter (a). - Homozygous: both alleles for a gene match, as in
AAoraa. - Heterozygous: the two alleles differ, as in
Aa. - Gamete: a reproductive cell (egg or sperm) that carries just one allele from each gene pair.
A dominant allele controls the phenotype whenever it is present. A recessive allele only shows up in the phenotype when both copies are recessive, as in aa.
How to calculate a Punnett square
- List the alleles, or gametes, that each parent can pass on.
- A monohybrid parent with genotype
Aacan pass onAora. - A dihybrid parent with genotype
AaBbcan pass on four possible gamete combinations:AB,Ab,aB, orab.
- A monohybrid parent with genotype
- Draw a grid. Put one parent's gametes across the top and the other parent's gametes down the side.
- Fill each cell by combining the gamete from its row with the gamete from its column. By convention, the dominant (uppercase) allele is written first, so a cell combining
aandAis writtenAa, notaA. - Read off the phenotype for each cell: any genotype with at least one dominant allele shows the dominant trait; a genotype with two recessive alleles shows the recessive trait.
- Count how many cells show each phenotype and reduce that count to a ratio.
Worked example: monohybrid cross (Aa × Aa)
Both parents are heterozygous, so each can pass on A or a.
| A | a | |
|---|---|---|
| A | AA | Aa |
| a | Aa | aa |
The four cells give three genotypes: AA (1 cell), Aa (2 cells), and aa (1 cell). That is a genotype ratio of 1:2:1.
For phenotype, AA and Aa both show the dominant trait, while only aa shows the recessive trait. That gives 3 dominant cells out of 4 and 1 recessive cell out of 4 — the classic 3:1 phenotype ratio.
Worked example: dihybrid cross (AaBb × AaBb)
Each parent can produce four gamete types: AB, Ab, aB, ab. Crossing two parents with four gamete types each produces a 4×4 grid of 16 cells. Sorted by phenotype, the 16 cells split into:
- 9 cells with both dominant traits (
A_B_) - 3 cells with the dominant A trait and recessive b trait (
A_bb) - 3 cells with the recessive a trait and dominant B trait (
aaB_) - 1 cell with both recessive traits (
aabb)
That is the standard 9:3:3:1 phenotype ratio for a dihybrid cross between two double heterozygotes.
Common monohybrid cross ratios
| Cross | Genotype ratio | Phenotype ratio |
|---|---|---|
| AA × AA | 100% AA | 100% dominant |
| AA × aa | 100% Aa | 100% dominant |
| AA × Aa | 50% AA, 50% Aa | 100% dominant |
| Aa × Aa | 25% AA, 50% Aa, 25% aa | 3:1 dominant to recessive |
| Aa × aa | 50% Aa, 50% aa | 1:1 dominant to recessive |
| aa × aa | 100% aa | 100% recessive |
Why the pattern works
The ratios above come from two rules Gregor Mendel described after breeding pea plants in the 1850s and 1860s.
Law of segregation: when a parent makes gametes, its two alleles for a gene separate. Each gamete carries only one. A parent with genotype Aa produces gametes that are half A and half a.
Law of independent assortment: for genes on different chromosomes, the allele passed on for one gene does not affect which allele is passed on for another gene. This is why a dihybrid cross can be worked out as two independent monohybrid crosses combined together. It does not hold for genes that sit close together on the same chromosome, since those tend to be inherited as a pair — a known limit of the basic Punnett square method.
Limitations of Punnett squares
Punnett squares work well for single genes with simple dominant-recessive inheritance, but several situations fall outside that model.
- Polygenic traits: traits like human height or skin color depend on many genes at once. A grid large enough to model them is not practical.
- Incomplete dominance: when neither allele fully dominates, heterozygotes show a blended trait. Crossing red and white snapdragons produces pink offspring, and the 3:1 ratio becomes 1:2:1.
- Linked genes: genes near each other on the same chromosome are usually inherited together, which breaks the independent-assortment assumption.
- Sex-linked traits: these need the X and Y chromosomes written into the genotype, for example
XᴴXʰfor a carrier mother. - Lethal alleles and variable penetrance: some allele combinations do not survive, or a gene may not always produce its expected trait, both of which skew the simple ratios.
For crosses involving three or more genes, or for these more complex patterns, geneticists generally use probability rules, pedigree charts, or population genetics models instead of a single grid.
Where Punnett squares are used
Biology classes use Punnett squares to make inheritance visible: two carrier parents (Ss × Ss) have a 25% chance of a child with the recessive condition, a fact a grid shows at a glance. Animal and plant breeders use the same method to estimate offspring traits before a cross, such as predicting coat color ratios in a litter of puppies. Genetic counselors use simplified Punnett squares to explain inheritance risk to patients, and conservation programs use them to plan breeding pairs for endangered species while limiting inbreeding.
History
Reginald Crundall Punnett devised the grid around 1905 while working with William Bateson, one of the scientists who championed Gregor Mendel's then-rediscovered work. Mendel had published his findings on pea plants in 1865, but they were largely overlooked until 1900, when three researchers — Hugo de Vries, Carl Correns, and Erich von Tschermak — independently rediscovered them. Punnett published the textbook Mendelism in 1909, which helped spread both Mendel's laws and the grid that now carries Punnett's name.
Frequently asked questions
What does a Punnett square show? It shows every possible combination of alleles two parents can pass to their offspring, along with the resulting genotypes and phenotypes.
What is the difference between genotype and phenotype?
Genotype is the genetic code, written as letters like Aa. Phenotype is the trait you can observe, such as flower color. Two different genotypes, AA and Aa, can produce the same phenotype if the trait is dominant.
Why does a 3:1 ratio show up so often?
It is the expected phenotype split when two heterozygous parents (Aa × Aa) are crossed. It is a probability over many offspring, not a guarantee for any single litter — much like flipping two coins does not guarantee one heads and one tails every time.
Can a Punnett square predict a real child's traits with certainty? No. It gives probabilities, not outcomes. A couple with a 50% chance of a trait per child could still have several children who all share the same trait, or none who do.
How do I handle more than two genes? A grid with three genes needs 64 cells and becomes impractical to draw. Geneticists typically work out each gene's probability separately, then multiply the independent probabilities together.
How is a test cross used?
A test cross reveals whether an organism showing a dominant trait is homozygous (AA) or heterozygous (Aa). Crossing it with a homozygous recessive (aa) parent gives all-dominant offspring if the parent was AA, or a 1:1 split of dominant to recessive offspring if the parent was Aa.
Building a Punnett square in code
The core steps are: split each genotype into its alleles, generate every gamete each parent can produce, then combine gametes pairwise, always writing the dominant allele first. This Python function follows that approach:
1def generate_monohybrid_punnett_square(parent1, parent2):
2 p1_alleles = list(parent1)
3 p2_alleles = list(parent2)
4
5 def combine(a, b):
6 # Dominant (uppercase) allele goes first
7 pair = sorted([a, b], key=lambda x: x.islower())
8 return ''.join(pair)
9
10 return [[combine(a1, a2) for a2 in p2_alleles] for a1 in p1_alleles]
11
12square = generate_monohybrid_punnett_square('Aa', 'Aa')
13for row in square:
14 print(row)
15# Output: ['AA', 'Aa']
16# ['Aa', 'aa']
17The key=lambda x: x.islower() line ranks uppercase letters (dominant) before lowercase letters (recessive), so sorted() always places the dominant allele first regardless of which parent it came from.
References
- National Human Genome Research Institute — Punnett Square
- Nature Education — Gregor Mendel and the Principles of Inheritance
- Khan Academy — Punnett Squares and Probability
- Pierce, B.A. (2017). Genetics: A Conceptual Approach (6th ed.). W.H. Freeman.
- Punnett, R.C. (1905). Mendelism. Macmillan and Company.