Since 2010 · Powering 2M+ tool runs every month
Since 2010
Add to Chrome

My Toolbox

Automatic Mode

No saved tools yet.

Go Premium
Related tools
Tessellation GeneratorPolar Equation PlotterParametric Curve GrapherTraveling Salesman Solver (TSP)Small Text Generator ⁽ᶜᵒᵖʸ ⁿ ᵖᵃˢᵗᵉ⁾
Home Page > Miscellaneous > General Tools

Spirograph Generator

Generate classic spirograph rosette patterns. Simulates the hypotrochoid and epitrochoid curves a pen traces as a small circle rolls inside or outside a larger one. Layer up to three pens, tune the radii, and export SVG or PNG.

Free to useNo sign-up requiredInstant Results
Spirograph GeneratorTry it now — free ▼
Try a preset:
Preview updates as you tweak each value. Click Generate for a high-resolution drawing with replay animation.

Embed Spirograph Generator Widget

● Pattern ready
8-petal curtate hypotrochoid Hypotrochoid — small circle rolls inside (classic) · 8-fold symmetry · 1261 sampled points · closes after 3 revolutions
8-petal curtate hypotrochoid — Hypotrochoid — small circle rolls inside (classic)
Drawn from R = 96, r = 36, d = 30, with gcd(R, r) = 12. The curve has 8-fold rotational symmetry and closes exactly after the rolling circle completes 3 revolutions.
R/r ratio: 96:36 1 pen Rainbow (full spectrum)
ModeInside
R / r / d96 / 36 / 30
GCD12
Lobes8
Pens1
Palette:
Copied ✓
Hypotrochoid parametric form — the pen is on the small circle rolling inside:
\( x(t) = (R - r)\cos t + d\cos\!\left(\dfrac{R - r}{r}\, t\right) \)
\( y(t) = (R - r)\sin t - d\sin\!\left(\dfrac{R - r}{r}\, t\right) \)
With R = 96, r = 36, d = 30, the curve closes after \( t \in [0, 2\pi \cdot 3] \).
📲

Install MiniWebtool App

Add to your home screen for instant access — free, fast, no download needed.

           

Want faster & ad-free?
Go Premium

About Spirograph Generator

The Spirograph Generator simulates the curves a classic Spirograph toy traces — beautiful, perfectly symmetric rosettes formed when a small circle rolls inside (or outside) a larger fixed circle while a pen on the small circle leaves a trail. The tool uses the real parametric equations behind hypotrochoids and epitrochoids, computes the exact loop period from the greatest common divisor of the two radii, and lets you stack up to three pens for a mandala effect. Tune three sliders, watch a live preview update in real time, then export the high-resolution curve as SVG or PNG.

How the Spirograph Math Actually Works

The dashed gray circle is the fixed circle of radius R. The violet disc rolls around its inside without slipping. A pen (orange) is mounted on the rolling disc at distance d from its center. As the rolling circle orbits, the pen leaves a curve. The animation here shows one full draw cycle on loop — your real spirograph below uses the same physics.

The key insight: the curve closes on itself only when the parameter angle returns to a multiple of \( 2\pi \) and the rolling circle has also made an integer number of full rotations. Both happen simultaneously after exactly r / gcd(R, r) orbits of the large angle. That is why this tool computes gcd(R, r) first — it guarantees the export is mathematically closed with no visible seam.

The Parametric Equations

Hypotrochoid (rolls inside)

$$x(t) = (R - r)\cos t + d\cos\!\left(\frac{R - r}{r}\, t\right)$$

$$y(t) = (R - r)\sin t - d\sin\!\left(\frac{R - r}{r}\, t\right)$$

If \( d = r \) the curve is a hypocycloid with sharp cusps (deltoid for 3 cusps, asteroid for 4). If \( d < r \) the curve has rounded petals (curtate). If \( d > r \) the petals form long loops (prolate).

Epitrochoid (rolls outside)

$$x(t) = (R + r)\cos t - d\cos\!\left(\frac{R + r}{r}\, t\right)$$

$$y(t) = (R + r)\sin t - d\sin\!\left(\frac{R + r}{r}\, t\right)$$

If \( d = r \) the curve is an epicycloid with outward-pointing cusps (cardioid for one cusp, nephroid for two). If \( d < r \) the loops are curtate; if \( d > r \) they are prolate.

What Makes This Spirograph Generator Different

Exact closure with no seam Most online spirographs sample a fixed number of revolutions and hope the ends meet. This tool computes r/gcd(R, r) first so the parameter range is mathematically exact — the last point lands on the first, every time, regardless of how strange the ratio is.
Live preview as you tweak The mini canvas next to the form re-draws on every keystroke and every slider change. You see the impact of changing R from 96 to 97 immediately, before committing to a full render. No more click-wait-click-wait.
Three-pen mandala mode Choose two or three pen layers and the same R/r ratio renders with smaller pen offsets in stacking colors. The curves nest like petals inside petals — a mandala from one set of inputs, not a hand-stitched composite.
Self-drawing reveal The SVG uses stroke-dashoffset animation so the curve traces itself in front of you, like a real pen on real paper. Click Replay drawing to watch it again — perfect for classrooms and presentations.
True vector export The SVG export is the original math — not a rasterized snapshot. Scale it to a billboard, send it to a laser cutter or embroidery digitizer, drop it into Illustrator or Inkscape for further editing. The PNG export is 2x–4x DPI for crisp slides and posts.
Built-in lobe counter Every result shows the gcd, the rotational symmetry (R/gcd), and the number of full revolutions needed to close. You learn the relationship between the integers and the visible shape just by changing one number at a time.

Counting the Petals: A Quick Guide

For a hypotrochoid, the number of lobes (or cusps, when \( d = r \)) equals \( R / \gcd(R, r) \). Some classic examples:

  • R = 4, r = 1, d = 1 → asteroid (4 cusps). The classic "diamond with caved-in sides".
  • R = 3, r = 1, d = 1 → deltoid (3 cusps). Also called the Steiner curve.
  • R = 96, r = 36, d = 30 → 8-petal rosette. Because \( \gcd(96, 36) = 12 \) and \( 96 / 12 = 8 \).
  • R = 105, r = 30, d = 72 → 7-petal star. Long, looping petals (because \( d > r \)).
  • R = 120, r = 45, d = 48 → 8-lobe lace. Slightly curtate petals interweaving.

For an epitrochoid the same formula applies with the "outside" geometry — \( R / \gcd(R, r) \) outward-pointing cusps when \( d = r \).

A Short History

The mathematics dates to Albrecht Dürer in 1525, who studied epicycloids while drawing geometric ornament. Roemer (1674) and Bernoulli (early 1700s) formalized the parametric equations. The toy most people know — the brightly colored plastic gears branded "Spirograph" — was invented by British engineer Denys Fisher in 1965 and released by Kenner the following year. It became a worldwide hit and won Toy of the Year (UK) in 1967. Fisher first developed the gear system to design intricate spring-loaded mechanisms; the toy was a happy accident.

Today, hypotrochoids and epitrochoids show up far beyond crafts: in Wankel rotary engines (the rotor traces an epitrochoid), in guilloché engraving on banknotes and luxury watches, in Lissajous-style oscilloscope art, and in generative-art tooling for posters, embroidery, and laser cutting.

Real-World Uses for the Output

  • Print and posters: a vector SVG at 8-petal rosette + gold palette + ivory paper makes a clean wedding-invitation flourish.
  • Laser cutting and engraving: the closed curve is one continuous stroke, ideal for machine paths. Export SVG and import to LightBurn or RDWorks.
  • Embroidery digitizing: the dense layered-pen mandala mode produces machine embroidery that runs cleanly without thread jumps.
  • Math and art classroom: change r by one and watch the petal count change — a visual proof of why gcd matters in periodic functions.
  • Generative art: the SVG export is editable. Open in Illustrator, fill the closed curve with a gradient, multiply-blend on a photo background.
  • Logo flourishes: the monochrome palette + single-pen + small d gives a thin elegant rosette that scales perfectly on business cards.

Tips for Beautiful Designs

  • Prime ratios = high lobe counts. Try R = 113, r = 30 (gcd 1, so 113 lobes — a dense lace). Then try R = 120, r = 30 (gcd 30, just 4 lobes — clean star).
  • Push d past r for loops. When \( d > r \) the petals overlap themselves — try R = 90, r = 36, d = 80 for a flower with self-intersecting petals.
  • Sub-unit d for soft petals. Small d values relative to r give a soft, "rounded daisy" look. Good for cards and gift tags.
  • Layer pens for depth. Same R, r, d but pen layers = 3 instantly creates a 3D-feeling concentric design without changing anything else.
  • Blueprint + ocean palette = engineering sketch. Use for tech-y illustrations and slide accents.
  • Graph paper + monochrome ink = textbook diagram. Perfect for printable math worksheets.

Frequently Asked Questions

What is a spirograph mathematically?

A spirograph traces a hypotrochoid (small circle rolling inside a larger fixed one) or an epitrochoid (small circle rolling outside). The curves are described by parametric equations with three radii: R for the fixed circle, r for the rolling circle, and d for the pen's offset from the rolling circle's center.

What do R, r, and d mean exactly?

R is the radius of the big fixed circle, r is the radius of the small rolling circle, and d is the distance of the pen from the center of the rolling circle. If d equals r the pen sits on the rim and the curve develops sharp cusps; smaller d gives soft rounded petals (curtate); larger d gives long looping petals that overlap (prolate).

Why does the pattern always close into a loop?

The tool computes the greatest common divisor of R and r. The curve closes exactly after r / gcd(R, r) revolutions of the rolling circle, and the result has R / gcd(R, r) lobes of rotational symmetry. Using the gcd guarantees the pen returns to its starting point with no visible seam, regardless of whether R/r is rational or not (we treat them as integers).

What is the difference between hypotrochoid and epitrochoid?

Hypotrochoid uses a small circle rolling on the inside of a larger one — this is the classic Spirograph toy. Epitrochoid uses a small circle rolling on the outside. Hypotrochoids feel like rosettes pointing inward (petals toward the center); epitrochoids feel like flower or gear shapes pointing outward (petals away from the center). Wankel rotary engines use an epitrochoid as the rotor housing.

What is the multi-pen mandala mode?

Selecting two or three pen layers re-traces the same curve with progressively smaller d values in different palette colors. Because each pen has its own offset, the layers nest like petals inside petals, producing a mandala or rangoli effect from a single set of inputs. No layered compositing required — it is one math result rendered as multiple strokes.

Can I export the spirograph?

Yes. Download SVG gives a vector file that stays crisp at any size — ideal for printing, embroidery digitizing, vinyl cutting, or further editing in Illustrator or Inkscape. Download PNG renders the pattern as a high-resolution raster image, suitable for slides and social posts. Copy code puts the raw SVG markup on your clipboard for embedding in a webpage or sending in chat.

Is the tool free to use?

Yes. The Spirograph Generator is free, runs entirely in your browser, requires no signup, and never watermarks exports. The patterns you generate are yours to use in personal and commercial projects — printed, sold, remixed, or sewn into a quilt.

Why are some curves spiky and others smooth?

The spike count comes from R / gcd(R, r) — that integer is the number of lobes. The spike shape comes from d: when d equals r you get sharp cusps (a hypocycloid or epicycloid), when d is smaller you get rounded petals (curtate), and when d is larger than r the petals form long self-intersecting loops (prolate). Change one number at a time to feel the relationship.

How is this different from a Lissajous curve?

Lissajous curves come from independent sinusoidal motion on the x and y axes — x(t) = A sin(at + δ), y(t) = B sin(bt). Spirographs come from a small circle rolling around a big one without slipping. Lissajous patterns sit on a rectangular frame; spirographs sit on a circular frame. They share the family resemblance because both are periodic 2D curves, but the mechanism differs.

Why does the live preview look slightly different from the final result?

The live preview uses a lower sample count to stay responsive on every keystroke. The final result samples 900 to 7,200 points (scaled with curve complexity) for a crisper rendering. The two agree mathematically; the difference is just resolution.

Reference this content, page, or tool as:

"Spirograph Generator" at https://MiniWebtool.com/spirograph-generator/ from MiniWebtool, https://MiniWebtool.com/

by miniwebtool team. Updated: 2026-05-19

General Tools:

Top & Updated:

Voronoi Diagram GeneratorMaze GeneratorSierpinski Triangle GeneratorView all →
Home Page > Miscellaneous > General Tools > Spirograph Generator
×

Do us a favor and answer 3 quick questions

Thank you for participating in our survey. Your input will help us to improve our services.

Where exactly did you first hear about us?

What is your favorite tool on our site?

if Other, please specify:

How likely is it that you would recommend this tool to a friend?

NOT AT ALL LIKELYEXTREMELY LIKELY

Likely score: (1-10)