How to Add a Paragraph Break After a Time Pattern in Word Using Find and Replace
Question details
The user wants to find time formats (such as 12:34:56) in a document and automatically insert a paragraph break immediately following them, without leaving a leading space on the new line.

- Product
- Microsoft Word
- Device & OS
- not provided
- Scenario
- Formatting a text transcript, chat log, or document that contains timestamps, where the text currently continues on the same line as the timestamp and needs to be separated into new lines.
- Observed behavior
- The text continues immediately after the timestamp pattern. The goal is to programmatically move the subsequent text to a new paragraph using the Find and Replace feature.
Before proceeding, it is highly recommended to enable paragraph marks (¶) on your Home ribbon so you can clearly see the new line breaks as they are generated by the Find and Replace operation.
Use Wildcards to Replace a Trailing Space with a Paragraph Break
This method uses Word's wildcard feature to capture the time format (HH:MM:SS) and its trailing space, replacing only the space with a paragraph mark to ensure clean formatting.
By grouping the time pattern and the space separately in your search query, you can retain the timestamp while converting the space directly into a paragraph break. This prevents your newly created paragraphs from beginning with an unwanted leading space.
Press Ctrl + H on your keyboard to open the Find and Replace dialog box in Word.
Click the 'More >>' button at the bottom of the dialog box, then check the box for 'Use wildcards'.
In the 'Find what' box, type: ([0-9]{2}:[0-9]{2}:[0-9]{2})( ). The first set of parentheses captures the 6-digit time format with colons, and the second captures the space immediately following it.
In the 'Replace with' box, type: \1^p. The '\1' instructs Word to keep the first capture group (the time pattern), and '^p' tells it to insert a paragraph break in place of the space.
Click 'Replace All' to automatically apply the paragraph breaks throughout your entire document.

Basic Wildcard Replacement (If No Trailing Space Exists)
Use this alternative method if your timestamps are directly attached to the next character without any spaces in between.
Format Timestamps Faster with WPS Writer
WPS Writer offers a powerful, intuitive Find and Replace tool that supports the exact same advanced wildcards and regular expressions as Microsoft Word. You can quickly reformat transcripts, logs, and complex documents with absolute precision.
- 1. Open Find and Replace: Open your transcript or log in WPS Writer and press Ctrl+H to open the dialog.
- 2. Enable Wildcards: Click on the 'Options' or 'More' button to expand advanced settings and check the 'Use wildcards' box.
- 3. Execute the Replacement: Enter your time pattern ([0-9]{2}:[0-9]{2}:[0-9]{2})( ) and replace it with \1^p, then click 'Replace All'.

Frequently Asked Questions
What does \1 mean in the Replace with box?
\1 refers to the first capture group defined by the first set of parentheses in the Find what box. In this scenario, it represents the exact timestamp pattern found, telling Word to paste the timestamp back into the document exactly as it was found without modifying it.
Can I use this method for a different time format like MM:SS?
Yes, you can easily adjust the wildcard pattern. For a shorter MM:SS format, use ([0-9]{2}:[0-9]{2})( ) in the Find what box. It will capture the four digits and the single colon.
Why is 'Use wildcards' greyed out or not visible in Find and Replace?
You need to click the 'More >>' button located in the bottom left corner of the Find and Replace dialog box. This expands the advanced search options menu where the 'Use wildcards' checkbox is located.
Why did my replacement text literally insert '^p' instead of a line break?
This usually happens if you accidentally typed a capital 'P' in the Replace with box. Word requires a lowercase 'p' (^p) to register the code as a paragraph mark. Double-check your replacement string to ensure it is lowercase.




