Written and reviewed by FormulaCraft Team. Each formula on this page is run through our verification engine before publishing.
Last reviewed:
=TEXT(ROW()-1,"0000")Computed by a real spreadsheet engine on the sample data below.
| ID | Name |
| Alice | |
| Bob | |
| Carol |
=TEXT(ROW()-1,"0000")→0000
Edit the grid or formula, then run it through a real spreadsheet engine — no signup.
Sample data — click any cell to edit
Need it for your exact data?
Describe your columns in plain English and get the precise formula for your sheet, with the right Excel or Sheets syntax.
No built-in one, but you can use a combination of RANDBETWEEN calls or a Google Apps Script function: =generateUUID() if you add the script.
Use ROW()-based IDs only if your table is stable. For robust IDs, generate them once with RANDBETWEEN and paste as values, or store them in a column that you manually populate.
Written and reviewed by FormulaCraft Team. Each formula on this page is run through our verification engine before publishing.
Last reviewed: