How To Insert Multiple Blank Rows in Excel

December 2016

Creating a macro in Microsoft Excel offers users the ability to automate repetitive and predictable tasks in the program, often saving hours of time.

Insert Blank Rows Between Data Entries

If you would like to create a macro that will insert 2 blank rows into an existing spreadsheet after every 2 data entries, there is an available macro that can help you do so. The end result should look like this:

Default layout:

After Macro:


Inserting Multiple Blank Rows Between Existing Data

Utilizing the following macro will get you the result pictured above:
Sub test()
Dim j As Long, r As Range
j = InputBox("type the number of rows to be insered")

Set r = Range("A2")
Range(r.Offset(1, 0), r.Offset(j, 0)).EntireRow.Insert
Set r = Cells(r.Row + j + 1, 1)
'MsgBox r.Address(the apostrophe in the beginning of this line makes this line non operable)
If r.Offset(1, 0) = "" Then Exit Do

End Sub

Related :

This document entitled « How To Insert Multiple Blank Rows in Excel » from CCM ( is made available under the Creative Commons license. You can copy, modify copies of this page, under the conditions stipulated by the license, as this note appears clearly.