Remove Double Paragraphs

I’m trying to remove all the double paragraphs in my document, but NOTHING ( ^p^p, \p) is working. Why does this have to be so difficult? It’s easy a pie in MSO365!

Possibly because reading is genuinely hard. The respective help page unfortunately has no feature to bring the wanted item to top; and one needs to read to the needed line:

^$ Finds an empty paragraph.

Similar questions:

  1. Find and Replace double paragraph breaks - #6 by PYS (2016-05-17)
  2. How to use find and replace to change double paragraph breaks to single - #2 by ajlittoz (2020-03-03)
  3. Find and replace double paragraph breaks & make paragraphs continuous - #2 by RGB-es (2019-09-03)
  4. Find double line breaks - #3 by LeroyG (2021-04-26)

It is not difficult unless you insist to use the same commands as with Microsofts office-suite. LibreOffice/OpenOffice have used regular expressions as option for search and replace for a long time, so using other syntax than Microsoft, but more familiar to users on unix/linux. And a paragraph is the “chunk” wich is fed to the match()-routine.
Solution was already told: search for empty paragraph ^$
If you need a clone for Word/Excel search elsewhere but I recommend the original.

thanks for the slam (ie, reading is genuinely hard). Don’t be a dick.

I tried these solutions, but they are from 2016 and don’t work. Thanks for trying.

^s doesn’t work either, BTW.

^s should search for small letter s at begin of a paragraph (if you found the checkbox for regular expressions) ?

Did it all, followed all advise w/o any advancement in the problem. The firm I consult for has pulled the plug, as LibreOffice is simply unable to simply do what MSO handles with ease. Thanks.

And don’t feel bad, folks. It’s no loss to us, as software costs are a tax write-off.

LibreOffice is VERY similar to Mozilla’s Thundbird app, as in it comes SO CLOSE to making things work that it’s frustrating. The problem we have there is that TBird will NOT send a range of emails to the printer as a single job, REQUIRING user input to name each file as a separate attachment. Which means one simply CANNOT select 3-4 emails and create a single PDF file for the client. Outlook can, but the feedback from Mozilla’s site has been “WTF do you want to do that? You’re stuck in old school thinking!” Well, my client (law firm) has elderly clientel who can’t/don’t/won’t open more than a single attachment. MSOffice allows a proper workflow, compared to the free alternatives.

Neither LibreOffice, nor Thunderbird, are really “ready for primetime” in the corporate world. In the words of Maxwell Smart, “Missed it by THAT much! Sorry, Chief.”

Your regular expression is faulty.

^p^p will not match anything. First a regular expression has a range of a single paragraph. Yours tries to match ‘beginning of paragraph’ ^ followed by letter p, then another beginning of paragraph (which you can’t find inside a paragraph) and a letter p. Second your replacement string is a letter p with a useless escape (because p is sufficient by itself). In addition, there is no code for paragraph break in Writer repertoire.

What you really want is not to replace double paragraphs with a paragraph break but to remove empty paragraphs. Your regular expression should be ^$, i.e. start of paragraph- end of paragraph with nothing in between. Leave your replacement string empty.

Have you tried built-in help accessed through Help>LibreOffice Help or F1?

Actually, I want to use LibreOffice like we do MSO. It’s double-paragraph marks that I want to replace, NOT empty paragraphs. It probably sounds the same to you, but it’s actually something different for us. I don’t want to REMOVE double paragraphs, I want to REPLACE them with another placeholder ( ). So thanks, but it’s still not the solution I need.

The built-in help was useless, as was searching online. We’ll just stick with MSO, thanks.

What I REALLY want to do is replace two consecutive paragraph marks with another placeholder. NOT remove empty paragraphs. And the solutions I tried came directly from LibreOffice’s help file. Thanks for trying, but not an answer I can use.

Then it is hopeless. Writer is not Word. You must use it according to its rule or buy a M$ licence. By chance, do you save your documents .doc(x) so that you are more MSO-compliant? In this case, expect many compatibility issues and progressive damage to your documents.

You can’t match paragraph marks by themselves. As I mentioned above, Find & Replace is limited to a single paragraph contents excluding its boundaries. This means the paragraph break can’t be processed in any way, except in the case of empty paragraphs.
The only approximate surrogate is to put your placeholder inside an empty paragraph.

Side remark: I assume your document doesn’t use styling, does it?

In one point he is right: If he has even longer sequences of empty paragraphs or paragraph marks and needs to retain the “third mark” = second empty paragraph.
Maybe this could be done by extension alt-search, but I haven’t used it for years…
Edit: From extensions description:

Searched or replaced text can contain one or more paragraphs


It’s a plain text document. Don’t fret, my lil’ Raisinette. Two of the three board members have decided LibreOffice is too immature for our use. Thanks again.

Thank you for acknowledging the problem (unlike all others). Unfortunately, the firm I consult for has had enough. Today cost them >$400 in my fees with the only resultant being “LibreOffice is just not mature enough to handle what Microsoft Office does with ease and no re-training. This project is cancelled as of this email.” - Senior Partner/President of my client. But, I sure do appreciate you!

Many tricks I read around didn’t worked for me. My case is the same: how to remove double-paragraph returns (hidden char.: ¶)
My solution is by using the Alternate Search&Replace
It gave me this solution:
Search this:
Replace by:
(a simple return) or anything else you want

SOLVED: I searched first for the regular expression ^$ (which is one type of line break), and replaced it with QUINCE.

That left a whole bunch of new paragraphs, so I then, without undoing, replaced $ with QUINCE.

This left me with some QUINCE and some QUINCEQUINCE among a mass of words.

I replaced QUINCEQUINCE with \n\t and then QUINCE with \n.

Problem solved, looks perfect now (though the type formatting changed)

This was the most up-to-date version of LO as of Mar '24