How to generate a list of all possible 4 digits combinations in Excel?
In some cases, we may need to generate a list of all possible 4 digits combinations of number 0 to 9, which means to generate a list of 0000, 0001, 0002…9999. To quickly solve the list task in Excel, I introduce some tricks for you.
A list of all possible 4 digits combinations with formula
A list of all possible 4 digits combinations with List All Combinations 
List all possible 4 digits combinations with Insert Sequence Number 
A list of all possible 4 digits combinations with formula
In Excel, you can use below formula to list all possible 4 digits combinations of number 0 to 9.
Select a blank cell and type this formula =TEXT(ROW(A1)-1,"0000") into it, and press Enter key, then drag the autofill handle down until all the 4 digits combinations are listing.

A list of all possible 4 digits combinations with List All Combinations
With the formula to drag down until all combinations are listed is tedious. However, if you have Kutools for Excel installed, you can use its List All Combinations utility to quickly list all 4 digits combinations.
After installing Kutools for Excel, please do as below:(Free Download Kutools for Excel Now!)
1. Select a cell, A1, type 0 into it, then go down next cell and type 1 into it. And then select A1 and A2, and drag the autofill handle down until number 9 appears. See screenshot:

2. Then you need to format a column as Text (the column will put the combinations), click at a blank column header, says Column F, and then right click to select Format Cells, and select Text under Number tab in Format Cells dialog, and click OK . See screenshot:

3. Click Kutools > Insert > List All Combinations. See screenshot:

4. A List All Combinations dialog pops out, and you just need to do below operations:
(1) Select Value in the Type list;
(2) Click
to select your number list, (you also can directly type the numbers separated by commas into textbox), and click Add to add the first list into Combinations list;
(3) Repeat step (2) for three times to add other three number lists into Combinations list.

5. Click Ok. Now a dialog pops out to remind you select a cell to put the result, here you need to select the first cell of the column you format as Text.

6. Click OK. Now all the 4 digits combinations of 0-9 are listing.

Click here to know more about List All combinations
List All Possible 4 Digits Combinations
A List all possible 4 digits combinations with Insert Sequence Number
In Kutools for Excel, you can use Insert Sequence Number to solve this task, too.
After installing Kutools for Excel, please do as below:(Free Download Kutools for Excel Now!)
1. Select a large range of cells (more than 100000 cells), and click Kutools > Insert > Insert Sequence Number. See screenshot:

2. Then in the Insert Sequence Number dialog, do as below:
(1) Click New to create a new sequence. See screenshot:

(2) Type 0 as the Start number, 1 as the Increment, and 4 as the No. of digits, and check End number option and type 9999 into the textbox. See screenshot:

3. Click Add to add this sequence rule, and then click Fill Range. see screenshot:

Click here to know the details about Insert Sequence Number.
Insert All 4 Digits Combinations
The Best Office Productivity Tools
Kutools for Excel Solves Most of Your Problems, and Increases Your Productivity by
80%
- Reuse: Quickly insert complex formulas, charts and anything that you have used before; Encrypt Cells with password; Create Mailing List and send emails...
- Super Formula Bar (easily edit multiple lines of text and formula); Reading Layout (easily read and edit large numbers of cells); Paste to Filtered Range...
- Merge Cells/Rows/Columns without losing Data; Split Cells Content; Combine Duplicate Rows/Columns... Prevent Duplicate Cells; Compare Ranges...
- Select Duplicate or Unique Rows; Select Blank Rows (all cells are empty); Super Find and Fuzzy Find in Many Workbooks; Random Select...
- Exact Copy Multiple Cells without changing formula reference; Auto Create References to Multiple Sheets; Insert Bullets, Check Boxes and more...
- Extract Text, Add Text, Remove by Position, Remove Space; Create and Print Paging Subtotals; Convert Between Cells Content and Comments...
- Super Filter (save and apply filter schemes to other sheets); Advanced Sort by month/week/day, frequency and more; Special Filter by bold, italic...
- Combine Workbooks and WorkSheets; Merge Tables based on key columns; Split Data into Multiple Sheets; Batch Convert xls, xlsx and PDF...
- More than
300 powerful features. Supports Office/Excel
2007-2019 and 365. Supports all languages. Easy deploying in your enterprise or organization. Full features
30-day free trial. 60-day money back guarantee.
Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier
- Enable tabbed editing and reading in Word, Excel, PowerPoint, Publisher, Access, Visio and Project.
- Open and create multiple documents in new tabs of the same window, rather than in new windows.
- Increases your productivity by
50%, and reduces hundreds of mouse clicks for you every day!