What is the difference between SGML and XML?

Tom Lehman picture Tom Lehman · Apr 14, 2009 · Viewed 11.9k times · Source

All the Google results suck.

Answer

Matthew Lock picture Matthew Lock · May 4, 2012

SGML is much harder to parse than XML as it has things like implicitly closing tags that close automatically (without specifying a closing tag).

I suspect that SGML has such features as it was more common when SGML was introduced in the 80s for humans to directly create SGML by hand than is the case for XML today, and so these features saved lots of typing. For example the OED was marked up (by hand?) in SGML in the 80s.

enter image description here