Breaking a Document Up Based on Heading 1 Styles

Written by Allen Wyatt (last updated June 20, 2026)

Gwen has a long document that she wants to break into individual Word documents. She would like each Word document to contain all text that begins with a Heading 1 style. Thus, there would be however many documents as there are Heading 1 styles within the original document.

This can be accomplished with or without a macro. If you only need to do it once, then you can manually do the saving by working in Outline view. While in this view, to the left of each heading is a small circle with a plus sign in it. Click that circle, and the heading along with all subordinate paragraphs is selected. Thus, if you click the circle to the left of a Heading 1 paragraph, then everything under that heading, up to the next Heading 1 paragraph, is selected.

At this point, you can then press Ctrl+C, open a new document, and paste the content to that document. Save it using whatever name you want and then repeat the process for each additional Heading 1 in the original document.

If you need to do this process more often, on more documents, then a macro is definitely the way to go. The following is a simple macro that will essentially perform the steps just described:

Sub SeparateByStyleHeading1()
    Dim P As Paragraph
    Dim DocNum As Long
    Dim SourceDoc As Document

    Set SourceDoc = ActiveDocument
    If SourceDoc.Path = "" Then
        MsgBox "The active document must have been saved " & _
          "before this macro is run.", vbCritical
        Exit Sub
    End If

    DocNum = 0
    For Each P In SourceDoc.Paragraphs
        If P.Range.Style = SourceDoc.Styles(wdStyleHeading1) Then
            P.Range.Select
            SourceDoc.Bookmarks("\HeadingLevel").Range.Copy
            With Documents.Add(Template:=SourceDoc.FullName, _
              DocumentType:=wdNewBlankDocument)
                .Content.Paste
                DocNum = DocNum + 1
                .SaveAs2 SourceDoc.Path & Application.PathSeparator & _
                  "Part" & Format(DocNum, "0000") & ".docx"
                .Close
            End With
            SourceDoc.Activate
        End If
    Next P
End Sub

The macro works because the built-in \HeadingLevel bookmark refers to the heading level of the selected paragraph, along with any subordinate paragraphs—exactly what Gwen is looking for. Everything before the first Heading 1 paragraph is ignored and not saved to a new document.

When saving files, the macro saves them in the same folder as the document being processed. The files are named in the format Part0001.docx, with the number incrementing for each Heading 1 paragraph encountered. Before running the macro, you'll want to ensure that there are no other files in the folder that would cause a naming conflict with the files created by the macro.

Note:

If you would like to know how to use the macros described on this page (or on any other page on the WordTips sites), I've prepared a special page that includes helpful information. Click here to open that special page in a new browser tab.

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (11979) applies to Microsoft Word 2007, 2010, 2013, 2016, 2019, 2021, 2024, and Word in Microsoft 365.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Jumping Around Folders

When you open a workbook in Excel, the Open dialog box always starts within the folder in which you were last working. ...

Discover More

Using the SYMBOL Field

The most common way of adding symbols to a document is to use the Symbol dialog box. There is another way, however, that ...

Discover More

Printing Only Some Pages

I often need to print only select pages of a document, rather than the whole thing. Word makes it easy to be judicious in ...

Discover More

Do More in Less Time! An easy-to-understand guide to the more advanced features available in the Microsoft 365 version of Word. Enhance the quality of your documents and boost productivity in any field with this in-depth resource. Complete your Word-related tasks more efficiently as you unlock lesser-known tools and learn to quickly access the features you need. Check out Microsoft 365 Word For Professionals For Dummies today!

More WordTips (ribbon)

Creating Multiple Blank Documents in One Step

Word makes it easy to create a new, blank document. What if you want to create more than one document at a time, however? ...

Discover More

Opening Multiple Documents at Once

Word's Open dialog box provides many of the same file management functions as Windows Explorer does. One of the functions ...

Discover More

Read-Only Embedded Fonts

If you receive a document from somebody else, you might not be able to edit it if the document contains fonts that you ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is five minus 2?

There are currently no comments for this tip. (Be the first to leave your comment—just use the simple form above!)


This Site

Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.

Videos
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.