How geometric and dimensional constraints turn a rough sketch into a rock-solid, fully parametric 2D profile — the foundation of every good FreeCAD model.
If there's one skill that separates a frustrating FreeCAD experience from a smooth one, it's understanding the Sketcher. Almost every 3D feature in FreeCAD — a pad, a pocket, a revolve — starts life as a 2D sketch. And the thing that makes a sketch reliable, editable, and "parametric" instead of a fragile pile of lines is its constraint system.
In this post, we'll break down exactly what constraints are, the difference between geometric and dimensional constraints, how degrees of freedom work, and how to avoid the classic beginner mistake of an under- or over-constrained sketch.
What Is a Constraint, Really?
A constraint is a rule you apply to your sketch geometry that removes ambiguity about its size, shape, or position. Without constraints, a line you draw is just floating in space — nothing stops it from moving, stretching, or rotating when you edit something else.
Constraints lock that geometry down. Once a sketch is fully constrained, every point, line, and curve has an exact, predictable position, and the sketch turns solid green in FreeCAD's Sketcher — a visual confirmation that there's no ambiguity left.
Degrees of Freedom (DoF): The Core Concept
Every piece of geometry you draw has a number of "degrees of freedom" — ways it's still free to move or change. A constraint's job is to remove degrees of freedom, one or more at a time, until none are left.
FreeCAD shows your remaining degrees of freedom in the task panel and status bar as you sketch, so you always know how much work is left. A sketch can be in one of three states:
| State | Color | Meaning |
|---|---|---|
| Under-constrained | White / normal | Some geometry can still move freely — DoF remaining |
| Fully constrained | Green | Zero DoF — geometry is completely locked |
| Over-constrained / conflicting | Red / orange | Contradictory or redundant constraints applied |
Geometric Constraints
Geometric constraints define relationships between elements — not exact sizes, but how things relate to each other spatially. These are usually applied first, to establish the overall shape.
| Constraint | What It Does |
|---|---|
| Coincident | Snaps two points to the exact same location |
| Horizontal / Vertical | Forces a line to align to the X or Y axis |
| Parallel | Keeps two lines running in the same direction |
| Perpendicular | Forces two lines to meet at 90° |
| Tangent | Makes a line or curve touch a circle/arc smoothly |
| Equal | Forces two elements to share the same length or radius |
| Symmetric | Mirrors two points/lines about an axis or point |
| Point on Object | Locks a point so it must lie on a line or curve |
Dimensional Constraints
Dimensional constraints, on the other hand, define exact measurable values — lengths, angles, radii, and distances. These are what let you type in "25mm" and have your geometry snap to that precise size.
| Constraint | What It Does |
|---|---|
| Distance | Sets the length between two points, or a line's length |
| Horizontal Distance | Sets distance measured only along the X axis |
| Vertical Distance | Sets distance measured only along the Y axis |
| Radius / Diameter | Sets the exact size of a circle or arc |
| Angle | Sets the angle between two lines |
A Simple Workflow: Constraining a Rectangle
- Draw four connected lines roughly forming a rectangle.
- Apply
Horizontalto the top and bottom lines. - Apply
Verticalto the two side lines. - Apply
Coincidentat each corner (if not already snapped). - Add a
Distanceconstraint for width, and another for height. - Optionally, anchor one corner to the origin with a
Coincidentconstraint so the whole sketch is positioned predictably.
Once you've done this, the rectangle turns fully green — zero degrees of freedom remain, and it's ready to be padded into a 3D solid with total confidence that it won't shift later.
Common Beginner Mistakes
Handy Tips for Working Faster
- Use FreeCAD's auto-constraint feature while sketching — it applies obvious constraints (like coincident or horizontal) automatically as you draw.
- Keep an eye on the DoF counter in the Elements panel; it tells you exactly how many constraints you still need.
- Use the keyboard shortcuts (e.g.
Hfor horizontal,Vfor vertical,Cfor coincident) to speed up constraint application dramatically. - Right-click a constraint in the Elements list to quickly delete or rename it if your sketch is getting cluttered.
- Name important constraints (like key dimensions) so they're easy to find and edit later, especially in complex parametric models.
Wrapping Up
Mastering the Sketcher's constraint system is one of the highest-leverage skills you can build in FreeCAD. It's the difference between models that update gracefully when you tweak a dimension, and models that fall apart with every small change. Start every sketch with a clear plan: rough in geometry, apply geometric constraints to define relationships, then lock in dimensions — and always aim for that satisfying fully-constrained green.
Ready to Go From Confused to Confident in FreeCAD?
If sketches, constraints, and parametric modeling still feel overwhelming, our complete beginner course walks you through everything step by step — no prior CAD experience needed.
Enroll in the Complete FreeCAD for Beginners Course →