List.Numbers

List

Generates a list of numbers starting from a given value, with a specified count and optional increment.

Examples on this page use shared sample tables. View them to understand the input data before reading the examples below.

Syntax

List.Numbers(start as number, count as number, optional increment as nullable number) as list

Parameters

NameTypeRequiredDescription
startnumberYesThe starting number.
countnumberYesThe number of values to generate.
incrementnullable numberNoThe amount to add between each successive number. Defaults to 1 if not specified.

Return Value

listA list of numbers of length count, beginning at start and incrementing by the specified amount.

Remarks

List.Numbers generates an arithmetic sequence of numeric values — the numeric equivalent of List.Dates, List.Times, and related sequence generators. It is useful for creating index lists, generating test data, producing evenly-spaced values for axis labels, or building the basis for further transformations.

The increment parameter defaults to 1 if omitted or null. Use a negative increment to generate a decreasing sequence. Use a decimal increment for fractional steps (e.g., 0.1 for 10% increments, 0.25 for quarter-unit steps). A count of 0 returns an empty list.

For simple integer sequences starting at 0, the range literal {0..N} is more concise. For sequences starting at 1, {1..N} works equally well. List.Numbers is preferred when the start, count, or increment are dynamic values computed at runtime, or when the increment is non-integer.

Examples

Example 1: Generate integers from 1 to 5

Result
Result
1{1, 2, 3, 4, 5}

Example 2: Generate even numbers

List.Numbers(0, 6, 2)
Result
Result
1{0, 2, 4, 6, 8, 10}

Example 3: Countdown from 10

List.Numbers(10, 5, -1)
Result
Result
1{10, 9, 8, 7, 6}

Example 4: Decimal step (percentage increments)

List.Numbers(0, 5, 0.25)
Result
Result
1{0, 0.25, 0.5, 0.75, 1}

Compatibility

Power BI Desktop Power BI Service Excel Desktop Excel Online Dataflows Fabric Notebooks