Super User is a question and answer site for computer enthusiasts and power users. 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 have Notepad++ and XML Tools plugin installed. When I copy an XML file and paste it to the window. It became one line. How can I auo format it and make it readable?


The demo image likes: image

share|improve this question
up vote 2 down vote accepted

Plugins -> XML Tools -> Pretty Print (XML only - with line breaks)

share|improve this answer
It seems that version 6.5 doesn't have this plugin :( – St.Shadow Nov 29 '13 at 10:31

How about Plugins - XML Tools - Pretty Print (XML only - with line breaks)? Default shortcut Ctrl+Alt+Shift+B. This should make your XML very readable.

share|improve this answer

You will need TextFX plugin.

Then go for:

TextFX -> TextFX HTML Tidy -> Tidy: reindent XML

share|improve this answer
It is grayed out. It is not working but thanks. – Love Jul 27 '12 at 21:09
What NPP version do you have? I had a problem with libtidy.dll. – coelhudo Jul 27 '12 at 21:25

Better option is:

Plugins -> XML Tools -> Linarize XML

share|improve this answer
Does not this function format the XML back to a single line (i.e. contrary to what was asked for)? – pabouk Nov 7 '13 at 8:36

If you don't find the plugin you want to use (eg.: XML Tools), just add it by clicking:

Plugins -> Plugin Manager -> Show Plugin Manager

Find, select and install it. When you re-open Notepad++, it'll be listed under the Plugins menu. After that, do what they've already said: Plugins -> XML Tools -> Pretty Print (XML only - with line breaks)

share|improve this answer

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.