The Revolution Behind HTML

Reading time

~ 5 min read
Tags

css
Author

Mustapha Aouas
The Revolution Behind HTML

Imagine a world without the internet. No Google, no social media, no online shopping. It's hard to picture, isn't it? Yet just a few decades ago, this was our reality. The web as we know it today is built on a foundation of HTML (HyperText Markup Language), a simple yet powerful language that has been the backbone of web development for over 30 years. From e-commerce giants like Amazon and eBay to encyclopedic wonders like Wikipedia, and even quirky niche sites dedicated to cats that look like Hitler, HTML has enabled it all. But how did we get here? Let's embark on a journey through the fascinating history of HTML.

A Spark of Genius

Our story begins in 1989 at CERN, the European Organisation for Nuclear Research. Picture a young British computer scientist named Tim Berners-Lee, frustrated by the difficulty of sharing information between researchers. His solution? A revolutionary concept he called the World Wide Web.

In 1991, Berners-Lee proposed a document called "HTML Tags," outlining fewer than two dozen elements that could be used to create web pages. This wasn't a completely novel concept; Berners-Lee built upon the existing SGML (Standard Generalised Markup Language) format, which already used tags enclosed in angle brackets.

This decision to build on existing standards rather than reinventing the wheel would become a recurring theme in HTML's development. It's a philosophy that continues to influence the creation of HTML5 today.

 

Screenshot of the restored version of the first website (Image: CERN)
Screenshot of the restored version of the first website (Image: CERN)

HTML 1.0 HTML 2.0

Interestingly, there was never an official HTML 1.0 specification. The first standardised version was HTML 2.0, published by the Internet Engineering Task Force (IETF) in 1995. This specification was largely driven by existing implementations.

For example, let's talk about the birth of the <img> tag. In 1993, Marc Andreessen, co-author of Mosaic (one of the first web browsers), proposed the idea of an image element. The story goes that he announced it on the www-talk mailing list with a simple "I'd like to propose a new tag." This tag, which allowed images to be embedded directly into web pages, was quickly implemented in Mosaic and later incorporated into the HTML 2.0 specification.

The World Wide Web Consortium (W3C) took over from the IETF, publishing several iterations of the standard. The latter half of the 1990s saw a flurry of revisions, with new elements being added with each version. By the time HTML 4.0 was released in 1997, we had tables for layout (a blessing and a curse), frames (mostly a curse), and even the beginnings of CSS support.

XHTML as a “best practice”

After HTML 4.01 in 1999, the web faced its first major turning point with the introduction of XHTML 1.0. This marked a significant shift in the W3C's approach to web standards. XHTML, or eXtensible HTML, was an attempt to reformulate HTML as an XML-based language.

While the content of XHTML 1.0 was identical to HTML 4.01, it imposed stricter rules on how elements and attributes should be written. This stricter syntax was initially embraced by many web developers as a "best practice”. It encouraged consistency in coding style and coincided with the rise of CSS support in browsers, promoting the separation of structure and presentation.

For example, in XHTML, all tags had to be lowercase and properly nested, and all attributes had to be quoted:

<p><strong>This is correct</strong></p>
<p><strong>This is incorrect</STRONG></P>

Many developers saw XHTML as a step towards a more structured, professional web. Web design blogs and books touted the benefits of "semantic markup" and "valid code." The W3C even provided an online validator, and it became common to see "Valid XHTML 1.0" badges proudly displayed on websites.

However, the W3C's next step, XHTML 1.1, proved to be problematic. As a pure XML document, XHTML 1.1 couldn't be served with the traditional text/html MIME type but instead application/xhtml+xml. This created compatibility issues with Internet Explorer, the dominant browser at the time.

Imagine the frustration of a web developer who had meticulously crafted a perfectly valid XHTML 1.1 document, only to find that it wouldn't render properly in the most widely used browser!

The push for XML

The W3C continued to push for an XML-based web with XHTML 2. This new standard was not designed to be backwards compatible with existing HTML or XHTML 1.x documents. Instead, it aimed to be a theoretically pure language, free from the constraints of its predecessors.

To give you an idea of how different XHTML 2 was going to be, consider this: it was going to deprecate the <img> tag in favour of a more generic <object> tag. The <h1> through <h6> heading tags were to be replaced with a single <h> tag that derived its level from its nesting depth… While these ideas were interesting in theory, they would have required a complete overhaul of existing web content and development practices.

This direction didn't sit well with everyone. Representatives from Opera, Apple, and Mozilla grew dissatisfied with the consortium's focus on theoretically pure standards that seemed divorced from the needs of web developers.

In 2004, Ian Hickson, then working for Opera Software, proposed extending HTML to improve forms and better support web applications. When this proposal was rejected by the W3C, Hickson and others formed the Web Hypertext Application Technology Working Group (WHATWG) 💕.

The birth of HTML5

The WHATWG operated differently from the W3C, with a more agile process. They began work on Web Forms 2.0 and Web Apps 1.0, which eventually merged into what we now know as HTML5.

By 2006, it had become clear that the W3C's attempt to transition the web from HTML to XML wasn't working. In a significant shift, the W3C formed a new HTML Working Group and decided to use the WHATWG's work as the basis for the next version of HTML.

This led to a period of confusion, with the W3C working on both XHTML 2 and HTML 5 (note the space), while the WHATWG continued developing HTML5 (no space). Web developers were left scratching their heads, unsure which standard to follow.

The situation was finally simplified in 2009 when the W3C announced that it would not renew the charter for XHTML 2, effectively ending that branch of development. This decision was met with relief by many in the web development community, who saw it as a return to a more practical, evolutionary approach to web standards.

HTML5 represents a return to the pragmatic, evolutionary approach that characterised the early development of HTML. It builds on existing standards and practices, introducing new elements and APIs to better support modern web applications while maintaining backwards compatibility.

To illustrate how transformative these new features can be, let's consider video. Before HTML5, embedding video on a webpage typically required a plugin like Flash. This was often slow, insecure, and didn't work on all devices. With HTML5, we can embed video as easily as we embed images:

<video poster="cat-image.jpg" preload controls loop>
  <source src="cat-video.mp4" />
  <!-- Note that the support for all video formats (like MP4) can vary by browser, so it's often necessary to provide multiple formats for broader compatibility 👍 -->
  <source src="cat-video.webm" />
  A video of a cat playing the piano 🎹
</video>

This simple tag provides a native video player, complete with controls, that works across browsers and devices without any plugins.

One of the most significant aspects of HTML5 is its living standard nature. Rather than waiting for a complete specification to be finalised, browsers can implement features as they're developed. This allows web developers to start using new features as soon as they're supported, driving innovation and improving the web experience incrementally.

Wrapping up

The story of HTML is one of evolution, pragmatism, and occasionally, revolution. From its humble beginnings as a simple markup language proposed by Tim Berners-Lee to its current state as a powerful platform for web applications, HTML has come a long way. The shift towards XHTML marked a significant turning point, ultimately leading to the development of HTML5, which represents a return to HTML's pragmatic roots while pushing forward into the future.

The web has always been about innovation and adaptation. From the first website (which you can still visit at http://info.cern.ch/hypertext/WWW/TheProject.html) to modern web applications that rival native mobile apps in functionality, HTML has been at the heart of this evolution.