WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I see a lot of posts here and elsewhere having trouble adding line breaks for some reason, but I'm trying to remove them. I'm new to WP, and I see that when editing in "HTML" mode the text is rendered in paragraph tags for double line breaks, and <br> for single line breaks, without the need to write the HTML. This is nice, but when I format the code manually by adding the <p> tags myself, I still get <br>s in the output. Example input in the editor:

I don't want
HTML line breaks.

My output:

I don&#8217;t want<br />
HTML line breaks.</p>

I could remove all the line breaks in the source input, but that's really quite tedious and makes things harder to read in the editor. Is there any way to make WP ignore line breaks (not create <br>) when the content is already wrapped in <p> tags?

I'm using the defaults for everything on a new installation.

share|improve this question

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.