Knit Math

Knitting gauge calculator

Cast on 100 stitches. At your gauge they measure 20.00 in across. Work 130 rows for a length of 20.00 in.

Your numbers

Half stitches count: enter them as a decimal.

Measure inside the edges of a washed, dry swatch.

Rows or rounds.

The length those rows cover.

For a piece knit in the round, the circumference.

Only used for the rows.

The repeat of your stitch pattern. Leave it at one for plain fabric.

Edge or balancing stitches added once to the repeats. Must be fewer than the multiple.

Down keeps the piece no wider than asked, up no narrower.

Examples

Result

Stitches to cast on

100

Width of that count

20.00 in

Stitches before fitting the multiple

100.0

Rows to work

130

Length of those rows

20.00 in

Stitches per inch

5.00

Rows per inch

6.50

Stitches per ten centimeters

19.7

Rows per ten centimeters

25.6

Breakdown

How it works

Count the stitches across a measured width of your swatch and the rows over a measured length. The tool divides one by the other to get stitches per inch from a swatch of any size, multiplies by the width you want, and that is how many stitches to cast on. A cast on calculator that stops there gives counts that do not fit a rib or a lace repeat, so you can enter the stitch multiple and the extra stitches, and the count moves to one that fits. The width shown is the width of that final count. How many rows to knit for a length is the same sum with the row gauge.

Formula

stitches per inch = swatch stitches ÷ swatch width. Stitches for the width = width × stitches per inch, then moved to a count that fits the stitch multiple (repeat × whole number + extra stitches). Real width = cast-on stitches ÷ stitches per inch. Rows = length × rows per inch, to the nearest whole row.

Worked example

The calculator opens with this example; the result above is computed from it.

InputValue
Swatch: stitches counted20
Swatch: counted over a width of4 in
Swatch: rows counted26
Swatch: counted over a length of4 in
Width you want20 in
Length you want20 in
Stitch multiple1
Plus extra stitches0
Fit the multiple by goingTo the nearest count
Stitches to cast on100
Width of that count20.00 in
Stitches before fitting the multiple100.0
Rows to work130
Length of those rows20.00 in
Stitches per inch5.00
Rows per inch6.50
Stitches per ten centimeters19.7
Rows per ten centimeters25.6

Common cases

CaseStarting valuesStitches to cast onWidth of that countStitches before fitting the multipleRows to workLength of those rowsStitches per inchRows per inchStitches per ten centimetersRows per ten centimeters
Scarf in worsted weight yarnSwatch: stitches counted 18; Swatch: counted over a width of 4 in; Swatch: rows counted 24; Swatch: counted over a length of 4 in; Width you want 8 in; Length you want 60 in; Stitch multiple 1; Plus extra stitches 0368.00 in36.036060.00 in4.506.0017.723.6
Hat brim in two by two ribSwatch: stitches counted 22; Swatch: counted over a width of 4 in; Swatch: rows counted 30; Swatch: counted over a length of 4 in; Width you want 20 in; Length you want 8 in; Stitch multiple 4; Plus extra stitches 010819.64 in110.0608.00 in5.507.5021.729.5
Baby blanket with a twelve stitch repeatSwatch: stitches counted 16; Swatch: counted over a width of 4 in; Swatch: rows counted 22; Swatch: counted over a length of 4 in; Width you want 30 in; Length you want 36 in; Stitch multiple 12; Plus extra stitches 212230.50 in120.019836.00 in4.005.5015.721.7
Cowl with a charted repeatSwatch: stitches counted 24; Swatch: counted over a width of 4 in; Swatch: rows counted 24; Swatch: counted over a length of 4 in; Width you want 21 in; Length you want 12 in; Stitch multiple 24; Plus extra stitches 012020.00 in126.07212.00 in6.006.0023.623.6

Questions and answers

How many stitches do I cast on for a scarf?

At 18 stitches over 4 in, a scarf 8 in wide needs 36 stitches. For a length of 60 in at 24 rows over 4 in, work 360 rows.

How many stitches do I cast on for a hat?

At 22 stitches over 4 in, a hat that measures 20 in around needs 110.0 stitches. The nearest count that fits a two by two rib is 108, which measures 19.64 in.

Assumptions and limits

  • Measure the swatch after washing and drying it the way you will treat the finished piece.
  • Count over as wide a stretch as the swatch allows, away from the edges. Four inches is a little more than ten centimeters, so a gauge per four inches is not quite the gauge per ten centimeters.
  • When the count sits exactly halfway between two that fit, the nearest setting takes the lower one.
  • Row gauge changes more with blocking and wear than stitch gauge. For lengths, measuring the work as you go is safer than counting rows.

The result is an estimate for planning, not professional advice.

Sources

Last updated:

Method in depth: Gauge, stitch counts and finished size

Cite this page: Knit Math, “Knitting gauge calculator”, https://knit-math.pages.dev/gauge-and-yarn/knitting-gauge-calculator/ (updated 13 October 2026).

Found a mistake? Email handycalc.sites+knitmath@gmail.com.