apps-script-utils 2.1.1 Help

getColumnLetterByIndex

function getColumnLetterByIndex(columnIndex: number): string;

Indices count from zero, the way a GridRange does; positions count from one, the way getRange(row, column) does. Mixing the two is the usual source of an off-by-one in a spreadsheet script, which is why both pairs exist under separate names.

Parameters

Parameter

Type

Description

columnIndex

number

The zero-based column index (e.g., 0 for 'A').

Returns

string — the column letter.

Examples

Converting

getColumnLetterByIndex(0); // => "A" getColumnLetterByIndex(26); // => "AA"

See also

Source

src/appsscript/sheet/getColumnLetterByIndex.ts

23 September 2026

This documentation was generated with AI (Claude) from the library's source code.