Auto bed leveling

Also known as: ABL

On this page 7

Auto bed leveling (ABL) is a firmware feature that measures the height of the build surface at a grid of points with a probe and then compensates for tilt and warp by moving the Z axis while the printer lays down each layer. In FDM printing, it addresses the most sensitive step of any print: a uniform first layer pressed onto the bed at the correct distance from the nozzle.

Despite its name, ABL rarely makes the bed physically level. It builds a height map, often called a mesh, and applies software correction. The bed can stay slightly crooked while the nozzle follows its shape, which is why ABL works alongside, not instead of, a correctly set Z offset and a mechanically sound frame.

How auto bed leveling measures and corrects the bed

Auto bed leveling works in two phases: probing and compensation. During probing, the printer moves a sensor to predefined XY positions and lowers it until it triggers, recording the Z coordinate at each point. The firmware stores these values as a matrix and, during printing, interpolates the height between measured points for every move.

Compensation is applied as a small Z adjustment added to every move. Most firmware fades the correction out over the first several millimeters of height, a setting called fade height, so that upper layers become flat again and the part does not inherit the bed shape. Marlin, Klipper and RepRapFirmware all implement this behavior with slightly different names.

Firmware offers several compensation models, and the right choice depends on how the bed deviates from a flat plane. The table below compares the common models.

ModelProbe pointsWhat it correctsTypical use
Three-point plane3Tilt onlyRigid, flat glass or cast plates
Linear least squares9 to 25Tilt, averaged over the gridFlat beds with small noise
Bilinear mesh9 to 100Tilt and moderate warpMost consumer printers
Unified bed levelingUp to 225 or moreDetailed warp, editable meshLarge or uneven beds
Common compensation models in printer firmware

Probe types used for bed leveling

The probe determines the accuracy and repeatability of the whole system. A good probe repeats within about 0.005 to 0.02 mm, which is well below the thickness of a typical first layer of 0.2 mm. Each sensor type has its own trigger mechanism and material limitations.

Probe typeTrigger principleBed surfacesMain limitation
Inductive probeEddy currents in metalSteel or aluminum onlyDrifts with temperature
Capacitive probeChange in capacitanceMost materialsSensitive to humidity and heat
BLTouch-style pinRetractable pin switchAny surfaceMechanical wear, slower
Nozzle contact sensorLoad cell or strain gaugeAny surfaceNeeds a clean nozzle tip
Eddy current scannerContinuous distance readingConductive bedsRequires thermal calibration
Probe types and their characteristics

Probes that sit beside the nozzle measure the bed at an XY offset from the nozzle, so the firmware must know that offset precisely. Sensors that use the nozzle itself as the probe, such as load cells, remove the offset error entirely and measure the actual point of contact, which is why many recent printers adopt them.

Auto bed leveling is one of several first-layer adjustments, and confusing them is a frequent cause of failed prints. Manual leveling, Z offset and tramming each solve a different part of the problem.

AdjustmentWhat it setsHow oftenRelation to ABL
Manual levelingPhysical bed tilt via screwsAfter transport or repairsReduces the correction ABL must apply
Z offsetAbsolute nozzle-to-bed distanceAfter nozzle or plate changesRequired in addition to ABL
Gantry trammingParallel X axis on two Z motorsAfter crashes or movesABL cannot fully fix a racked gantry
Auto bed levelingRelative height shape of the bedEvery print or on scheduleCorrects remaining deviation
How auto bed leveling relates to other calibrations

The key distinction is between relative shape and absolute distance. The mesh describes how the bed varies from point to point, while the Z offset defines where zero is. A perfect mesh with a wrong offset still produces a first layer that is too squished or too loose everywhere.

Configuring a reliable probing routine

Good results come from probing under printing conditions. The bed and, ideally, the hotend should reach their working temperatures and stabilize for several minutes, because a heated bed can change shape by 0.05 to 0.2 mm compared with its cold state.

  • Use a grid density that matches the warp: 5 by 5 suits most 220 mm beds, while beds above 300 mm benefit from 7 by 7 or more.
  • Choose between a stored mesh and probing before each print; a fresh mesh catches changes but adds one to three minutes.
  • Enable adaptive or local meshing where firmware supports it, so only the area under the part is probed.
  • Keep the probe area inside safe margins, since edges near clips or magnets may read inaccurately.
  • Verify the result with a first-layer test pattern, not only with the numeric mesh.

A mesh range, the difference between the highest and lowest point, of under 0.3 mm is generally easy to compensate. Larger ranges indicate a mechanical problem worth fixing first, because heavy compensation introduces visible Z movement in the lower layers.

Limitations and common mistakes

Auto bed leveling cannot correct mechanical faults that change from one moment to the next. Loose wheels, a wobbling bed carriage or a slipping Z coupler produce errors the mesh does not describe. The table below links common symptoms to their causes.

SymptomLikely causeFix
Even squish but too thin everywhereZ offset too lowRaise the offset in small steps
Good center, poor cornersMesh too coarse or margins too wideAdd probe points, check edges
Mesh changes between runsProbe drift or loose mechanicsRecalibrate probe, tighten hardware
Mesh seems ignoredLeveling not enabled after homingLoad or activate the mesh in start code
Typical first-layer problems with ABL enabled

A frequent configuration error is a start script that homes after loading the mesh, which on some firmware disables compensation. Another is a dirty nozzle on contact probes, where a blob of filament adds a false height that shows up as an apparent bump in the bed.

A plain-language summary

A 3D printer builds parts by laying plastic onto a flat plate. The first layer must sit at the same tiny distance everywhere. But no plate is perfectly flat. Some corners are a little higher. Some spots sag.

Auto bed leveling lets the printer feel the plate before it prints. A small sensor taps the surface at many points and draws a height map. While printing, the nozzle then rises and dips slightly to follow that map. It works like a careful painter who notices bumps in a wall and adjusts the brush pressure. The plate stays the same, but the first layer comes out even.

An example from practice

A small product design studio runs a printer with a 300 by 300 mm aluminum bed that is slightly concave after years of heating cycles. Large flat enclosures kept failing at the corners, where the first layer barely touched the plate and lifted after an hour of printing.

The technician first adjusted the bed screws to remove the obvious tilt, then configured a 7 by 7 bilinear mesh probed with the bed at 60 °C after a five-minute soak. The measured mesh range dropped from 0.42 mm before the screw adjustment to 0.18 mm after it, and a fade height of 10 mm returned upper layers to true flatness.

After a single first-layer test to refine the Z offset by 0.03 mm, the enclosures printed with consistent adhesion across the full plate. Failed overnight prints, which previously wasted several hundred grams of filament each week, became rare.