---
tag: m0110
title: Set Line Number
brief: Set the current line number.
author: thinkyhead

group: hosts

codes: [ M110 ]

notes:
  - 'All these are valid: `N100 M110`, `M110 N100`, `N101 M110 N100`.'

parameters:
  -
    tag: N
    optional: false
    description: Line number
    values:
      -
        tag: line
        type: int

examples:

---

Hosts can use [`M110`](/docs/gcode/M110.html) to set the current line number in a print job. Each line number sent by a host must be one higher than the previous line number, or the firmware will ignore the line and send an error requesting a resend of the missing line. This is one technique Marlin uses to keep in sync with hosts.
