Sex determination: XX and XY chromosomes, and why each child is a 50 percent chance of a boy or a girl

Cross an XX mother with an XY father, then simulate up to 10 000 births and families. See the share of girls settle near half and why earlier children never change the next one.

Keep it one tap away for everyday use.

Bookmark Sex determination?

Press Ctrl + D now. Your browser opens its own bookmark box, where you choose the name and folder.

  1. Cross
  2. Simulate
  3. Compare
  4. Check
Nothing is uploadedWorks offline once open

The cross: XX mother, XY father

Every egg carries an X. A father's sperm carry an X or a Y, half each. Whichever sperm wins decides the child.

X (father)Y (father)
X (mother)XXXY
X (mother)XXXY

Simulate many births

Try this

  • Simulate only 10 births, several times. The share of girls jumps about. Then try 10 000: it settles near half.
  • Set 3 children per family. Families with three girls still happen about 1 in 8 times, yet the fourth child is again 50 : 50.
  • Who decides the child's sex, the mother or the father? Look at the Punnett square.

Check yourself

What it does

In humans, sex is set by a pair of sex chromosomes. A mother has two X chromosomes (XX), so every egg she makes carries an X. A father has one X and one Y (XY), so half his sperm carry X and half carry Y. If an X sperm meets the egg the child is XX, a girl. If a Y sperm does, the child is XY, a boy.

The Punnett square shows two XX and two XY outcomes, so each child has a 50 % chance of being a girl. The simulator then makes thousands of births to show that overall the share lands near half, while small families vary a lot. To see the same method with other traits, try mendel's pea garden and punnett square.

How to use it

  1. Read the cross at the top.
  2. Choose how many births to simulate and how many children per family.
  3. Press Simulate births and read the bar chart and the totals.
  4. Press it again with fewer births to see how much a small sample jumps about.

What each setting does

  • Births: how many children are made. More births land closer to 50 %.
  • Children per family: groups the births into families and shows how many girls each family has.
  • Class 11: draws the exact chances, C(n, k) / 2^n, as black lines over the bars.

Worked example

For 3 children per family there are 8 equally likely patterns, so 3 girls has chance 1/8 = 12.5 % and 1 girl has 3/8 = 37.5 %. Simulate 10 000 births and the bars sit close to those values. The girls overall come to about 5 000.

FAQs

Does the mother decide? No. Every egg carries an X, so the sperm decides.

After three girls, is a boy “due”? No. Each child is a fresh 50 : 50 chance.

Why is it not exactly half? Chance. A sample of 10 000 is usually within about a percentage point of half, but rarely exact.

Where the numbers come from

  • In humans a female has two X chromosomes (XX) and a male has one X and one Y (XY); the sperm decides the sex. The family-size chances are the binomial C(n, k) / 2^n, checked in the tests. This is standard school biology and probability.
  • The simulation is a teaching model of equal numbers of X and Y sperm. Drawings are fibub's own. Nothing you do on this page is stored or sent anywhere.

Standard scientific values, such as constants, atomic weights and melting points, are facts found in every textbook; we name where ours were checked. If you are an author or publisher and want a value, a credit or a table changed or removed, tell us and we will act quickly.

Last updated 2026-11-10.

Change log for Sex determination

  1. Add #1489 Sex determination Details on GitHub

Every change to fibub

Related tools

Punnett square #T202 Draw a Punnett square for 1 to 4 genes (complete, incomplete and codominant dominance, ABO blood groups, X-linked traits) and get the genotype and phenotype ratios as exact fractions. Use the branch method for up to 6 genes, the binomial rule for several children, and a Bayes table for carrier risk in a family. For learning, not genetic counselling. Mendel's pea garden #L58 Cross tall and short pea plants, or round yellow and wrinkled green seeds, and grow 20, 100 or 1000 random children. Compare the counts with 3 : 1 and 9 : 3 : 3 : 1, see the Punnett square, and at Class 12 level add incomplete dominance, codominance (ABO) and a chi-square check. Osmosis lab #L55 Drop a potato piece, a raisin, an onion cell or a red blood cell into sugar or salt water and watch water move in or out. See plasmolysis, a % mass change graph, water potential at Class 11 level, a virtual practical and quick questions. Photosynthesis lab #L56 Move a lamp, add carbon dioxide and warm the water around a pondweed, then watch and count the oxygen bubbles. See which factor is limiting the rate, and graphs of rate against light at several carbon dioxide levels (Blackman's law). Cell explorer #L57 Tap the parts of a plant cell, an animal cell and a bacterium to see what each one does, zoom in, compare the three cells in a table and work out how much the drawing is magnified. Class 9 and Class 11 levels, with quick questions. Central dogma lab #L59 See a gene's coding strand, template strand, mRNA and amino acids codon by codon with the standard genetic code. Tap a base to change, insert or delete it, and find out whether the change is silent, missense, nonsense or a frameshift.