\refstepcounter (LaTeX2e unofficial reference manual (November 2018))

Next: \stepcounter, Previous: \addtocounter, Up: Counters [Contents][Index]

### 13.6 `\refstepcounter`

Synopsis:

    \refstepcounter{counter}

Globally increments the value of counter by one, as does `\stepcounter` (see \stepcounter). The difference is that this command resets the value of any counter numbered within it. (For the definition of “counters numbered within”, see \newcounter.)

In addition, this command also defines the current `\ref` value to be the result of `\thecounter`.

While the counter value is set globally, the `\ref` value is set locally, i.e., inside the current group.

Unofficial LaTeX2e reference manual