I would like a notepad for Mac OS that pretty prints JSON and XML copied from a server console, just like notepad++ did on pc with JSON and XML plugins.
Have a look at Atom. It provides XML and JSON syntax highlighting.
On the lower right corner click on Plain text if auto-detection does not work (e.g. when copying example XML into the editor) and select XML or JSON.
CudaText works on macOS, and it has plugins for pretty printing of JSON and XML. They are named
JSON Format, and
XML Format. Install them via
Plugins / Addon Manager.
To enable plugins, you must install Python engine from python.org.