1) What are differences between XML and HTML?

  S.N   XML                                 HTML
  o
  1     XML provides user definable         HTML provides defined set of
        tags                                tags designed for web display
  2     XML is content driven               HTML is format driven
  3     End tags are essential in a         End tags are not always
        well formed XML document. In        required.<HTML> tag needs an
        a well formed document,             equivalent </HTML> tag but
        elements can be defined as          <br> tag does not require
        single tag or a pair of tags like   </br> tag
        <student/> or the
        <student>…</student> pair
  4     Quotes required around              Quotes are not required for the
        attribute values                    values of attributes
  5     Slash required in empty tags        Slash not required
  6     XML is used for describing          HTML is used for designing
        data                                pages

HTML and XML Difference FAQs

  • 1.
    1) What aredifferences between XML and HTML? S.N XML HTML o 1 XML provides user definable HTML provides defined set of tags tags designed for web display 2 XML is content driven HTML is format driven 3 End tags are essential in a End tags are not always well formed XML document. In required.<HTML> tag needs an a well formed document, equivalent </HTML> tag but elements can be defined as <br> tag does not require single tag or a pair of tags like </br> tag <student/> or the <student>…</student> pair 4 Quotes required around Quotes are not required for the attribute values values of attributes 5 Slash required in empty tags Slash not required 6 XML is used for describing HTML is used for designing data pages