Gear rack generator: racks that mesh with the spur gears

Pick your pinion's module and pressure angle, then the number of teeth — the rack is exactly that many pitches long, with both ends in the middle of a tooth space, so printed segments join into a longer run. It uses the ISO 53 tooth form our spur gears are hobbed from, so the pair meshes with the designed 0.2 mm of backlash.

Open the generator →Edit with AI

Use it right here

The real generator runs in your browser: set the parameters, then download STEP or STL. Nothing to install, no sign-up.

Gear Rack Generator

The first open downloads the CAD engine (about 20 MB).

Parameters you can tune

Each parameter below rebuilds real geometry on every change — this is parametric CAD, not a scaled mesh.

ParameterDefaultRangeWhat it does
ModuleMODULE2 mm1 – 5Must match the pinion's.
Pressure anglePRESSURE_ANGLE20 °20 / 2520° on every catalogue rack; 25° only to match a 25° pinion.
Number of teethTEETH152 – 120Length = teeth × π × module; 15 at module 2 is MISUMI's 100 mm stock rack (94.25 mm).
Face widthFACE_WIDTH10 mm3 – 40At least the pinion's face width.
Height to pitch linePITCH_HEIGHT18 mm9 – 6018 at module 2 is the pitch line of a square-section rack (HPC, MISUMI stainless: 9 × module); KHK and MISUMI steel racks use 23.
Mounting holesHOLES00 – 6Sideways through the face width, evenly spaced, like KHK SRFD racks.
ScrewSCREWM4M3 / M4 / M5 / M6Hole and counterbore sizes from MISUMI's rack tables.
CounterboredCOUNTERBOREonon / offSinks the screw heads into the -Y face.

Every parameter can go in the page's link, so one link opens exactly the part you want. Example (Module 1.5, 40 teeth (188.5 mm), 2 mounting holes):https://www.forgent3d.com/en/generators/gear-rack-generator?MODULE=1.5&TEETH=40&HOLES=2

What's in the STEP file

STEP AP214 in millimetres, exact B-rep — it opens directly in SolidWorks, Fusion, FreeCAD, Onshape or Inventor, and goes straight into a CNC quote form. STL for the slicer is one click too.

How it compares

This generatorTypical online STL generatorVendor CAD library
Any size within the rangeYesYesCatalog sizes only
STEP with exact surfacesYesUsually an STL mesh onlyYes
Changes the sliders don't cover“AI edit” on the pageNoNo
Account needed to downloadNoUsually noOften

Let AI change it

Edit with AI on the page

Press “AI edit” in the generator and say what to change — a keyway, holes, a different shape. The AI edits the part's model.py and it rebuilds in your browser, with undo. A few edits a day are free without signing in; to keep the result or go further, copy it into your models and continue with the AI agent.

Edit with AI →

Keep going in your workspace

For bigger changes, several rounds, or a part you want to keep: copy it into your models (free account). The Forgent3D AI agent reads the model.py, edits it, rebuilds it and checks the result itself.

Copy and continue with the AI agent →

How it works

  1. 1.Open the generator — the model builds right in your browser, nothing to install.
  2. 2.Tune dimensions and options in the parameter panel; the geometry rebuilds live in 3D.
  3. 3.Export STL / STEP for printing — or ask the AI agent for features beyond the sliders.

FAQ

Where does the pinion go?

Its centre sits at the rack's pitch-line height plus the pinion's pitch radius (module × teeth / 2): with the defaults, 18 + 20 = 38 mm for a 20-tooth module-2 pinion. That is the mounting distance KHK gives for any rack and pinion.

How long a rack can I print in one piece?

At module 2, 40 teeth (251.33 mm) lying straight on a 256 mm bed, or 53 teeth across its diagonal; 35 teeth (219.91 mm, no room left for a brim) on a 220 mm bed. For a longer run, print segments and join them — the ends are made for it.

Which way up should I print it?

Gear printing guides lay the tooth profile flat on the bed — smooth flanks, strong roots — so print the rack lying on its side; the side mounting holes then come out as clean vertical holes. PETG for a working rack, 4 or more walls.

How do I make a module 2 rack about 200 mm long for a 20-tooth pinion?

200 / (π × 2) rounds down to 31 teeth, 194.78 mm: https://www.forgent3d.com/en/generators/gear-rack-generator?MODULE=2&TEETH=31 — the pinion's centre then sits 18 + 20 = 38 mm above the rack's bottom (pitch-line height + pitch radius). Make the pinion with the spur gear generator at the same module.

Can I join printed racks for a longer run?

Yes: every rack here is a whole number of pitches with both ends mid-space. Butt them, mesh a short piece of rack across the joint to set the pitch — the method KHK and MISUMI give for their racks — then screw or pin both to the base.

Can I sell prints made with these generators?

Yes. Models you generate and the STL / STEP files you export are yours: print them, sell the prints, or use them in a product. No attribution to Forgent3D is required.

More generators

Already have your own .scad file? Convert OpenSCAD to STEP → · Preview it in the browser →