
This is a free online Koch snowflake generator. Choose how many times each segment is replaced, pick the colors, and download the result as a PNG image with a transparent background.
The Koch snowflake is built from an equilateral triangle by a single rule applied over and over: take every straight segment, and replace its middle third by the two other sides of an equilateral triangle. After a few repetitions the straight edges are gone and a snowflake appears, with a border that is jagged at every scale.
Besides the snowflake, this tool also draws the antisnowflake, where the bumps point inwards and the shape becomes a star that eats itself, and the single Koch curve, which is one side of the snowflake on its own.
Everything runs directly in your browser. No image is uploaded to a server, and nothing needs to be installed.
Use the mouse wheel over the image to zoom in and out, and drag the image to move it. On a phone, use one finger to move the image and two fingers to zoom. The checkered squares show the transparent areas of the image: they are not part of the downloaded PNG file.
| Field | Description |
|---|---|
| Variant | Koch snowflake (bumps outwards), Koch antisnowflake (bumps inwards) or Koch curve (a single line instead of a closed shape). |
| Number of iterations | How many times every segment is replaced by four shorter ones. Iteration 0 shows the starting triangle, and each iteration multiplies the number of segments by 4. |
| Zoom, Rotation, Margin | How the fractal is framed inside the image. The margin is the empty space left around the drawing, in pixels. |
| Coloring | One flat color, or a gradient between two colors. On the outline the gradient follows the curve from the first segment to the last one; on a filled shape it runs from the top of the image to the bottom. |
| Fill the shape | Fills the inside of the snowflake. Not available for the Koch curve, which is an open line. |
| Line thickness | The thickness of the line, in pixels, when the shape is not filled. Use a thin line at high iterations, otherwise the bumps merge into a blur. |
| Transparent background | Leaves the background of the PNG transparent, so the snowflake can be placed over any color or image. |
| Resolution / Width / Height | The size of the generated image, in pixels. |
Take an equilateral triangle. Divide each of its three sides into three equal parts, and on the middle part build an equilateral triangle pointing outwards, then remove the base of that new triangle. The straight side has become four segments, each one third as long, with a spike in the middle. Now do the same to all twelve segments, and to the forty eight after that, forever.
The curve was published by the Swedish mathematician Helge von Koch in 1904. He was not looking for a pretty picture: he wanted a simple, geometric example of a curve that is continuous everywhere but has a tangent nowhere. Weierstrass had already produced such a curve with a formula in 1872, but it could not be drawn or pointed at. Koch's snowflake can be built with a ruler.
The snowflake has a finite area — it always stays inside the circle that goes through the corners of the starting triangle, and its area converges to exactly 8/5 of the area of that first triangle. But its perimeter is infinite: each iteration multiplies the length by 4/3, and (4/3)n grows without limit. You could paint the inside of the snowflake with a finite amount of paint, but you could never trace its border.
Its fractal dimension is log 4 / log 3 ≈ 1.262: the curve is made of 4 copies of itself, each scaled by one third. This is the number that made "how long is the coast of Britain?" a famous question — a coastline behaves in the same way, getting longer the more closely you measure it.
| Variant | How it differs | What it looks like |
|---|---|---|
| Koch snowflake | Starts from a triangle, with every bump pointing away from the center. | A six pointed snowflake whose edges grow finer and finer, the classic shape. |
| Koch antisnowflake | Starts from the same triangle, but every bump points towards the center. | A three lobed shape that looks like it is being eaten from the outside in. Its area shrinks instead of growing, ending at 2/5 of the starting triangle. |
| Koch curve | Starts from a single straight segment instead of a triangle. | One side of the snowflake: a jagged line with a big central peak. Three of them joined make the snowflake. |
Yes, this tool is 100% free and works directly in your browser, with no installation and no sign-up required.
Are the images uploaded to a server?No. The snowflake is drawn by your own browser and the image never leaves your computer.
Can I use the generated images in my own projects?Yes. The images come from a geometric rule, and you are free to use them in websites, cards, posters, worksheets, games and printed material.
Can I download it with a transparent background?Yes. Turn on "Transparent background" and the PNG will have no background, which is what you want for a snowflake you intend to place over a photo or a colored card.
How many iterations should I use?Four or five is usually the sweet spot: the shape is clearly a snowflake and every bump is still visible. Above six, the smallest bumps get close to the size of a pixel, so raise the resolution or zoom into one edge to see them.
Why does the outline look like a thick blur at high iterations?Because the line is thicker than the details it is drawing. Lower the "Line thickness" to 1 pixel or less, or raise the resolution of the image.
Is the perimeter really infinite?Yes. Every iteration replaces each segment by four segments of one third of the length, so the total length is multiplied by 4/3 each time. Repeated forever, that grows beyond any number, even though the whole shape stays inside a small circle.
What is the area of the snowflake?Exactly 8/5 of the area of the triangle you started from. Each iteration adds smaller and smaller triangles whose total area forms a geometric series that converges.
Can I draw the Koch snowflake with turtle graphics?Yes, and it is a classic exercise: the snowflake is written in the L-system notation as F++F++F with the rule F → F-F++F-F and turns of 60 degrees. Our Turtle Graphics tool can draw it that way.
Where can I see other fractals?Try the Sierpinski Triangle Generator, the Dragon Curve Generator, the Barnsley Fern Generator and the Mandelbrot Set Generator.





