HTML is an abbreviation for HyperText Markup Language while XML stands for eXtensible Markup Language. Actually it is clear in mind that XML is not a replacement for HTML. In most web applications, XML is used to transport data, while HTML is used to format and display the data. To design XML and HTML have different goals like XML was designed to transport and store data, with focus on what data is. And that of HTML was designed to display data, with focus on how data looks. XML is now as important for the Web as HTML was to the foundation of the Web. XML is the most common tool for data transmissions between all sorts of applications.
The Difference are as follows:-
1.HTML focus on how data looks and it was designed to display data while XML focus on what data is and it was designed to be a software and hardware independent tool used to transport and store data.
2.HTML is a markup language itself while XML provides a framework for defining markup languages.
3.HTML is a presentation language while XML is neither a programming language nor a presentation language.
4.HTML is case insensitive while XML is case sensitive.
5.HTML is used for designing a web-page to be rendered on the client side while XML is used basically to transport data between the application and the database.
6.HTML has it own predefined tags while what makes XML flexible is that custom tags can be defined and the tags are invented by the author of the XML document.
7.HTML is not strict if the user does not use the closing tags but XML makes it mandatory for the user the close each tag that has been used.
8.HTML does not preserve white space while XML does.
9.HTML is static which is about displaying data, but XML is dynamic hence it is about carrying information.
Thus,it can be said that HTML and XML are not competitors but rather complement to each other
and clearly serving altogether different purposes.