HTML 5 is the fifth and current major version of the HTML standard, and subsumes XHTML. It currently exists in two standardized forms: HTML 5.2 Recommendation by the World Wide Web Consortium (W3C, a broad coalition of organizations), intended primarily for Web content developers; and HTML Living Standard by WHATWG (a small consortium of four browser vendors), intended primarily for browser developers, though it also exists in an abridged Web developer version. There are minor conflicts between the two groups' specifications.
HTML 5 was first released in public-facing form on 22 January 2008, with a major update and "W3C Recommendation" status in October 2014. Its goals are to improve the language with support for the latest multimedia and other new features; to keep the language both easily readable by humans and consistently understood by computers and devices such as Web browsers, parsers, etc., without XHTML's rigidity; and to remain backward-compatible with older software. HTML 5 is intended to subsume not only HTML 4, but also XHTML 1 and DOM Level 2 HTML; the HTML 4 and XHTML specs were announced as superseded by HTML 5.2 on 27 March 2018.
HTML 5 includes detailed processing models to encourage more interoperable implementations; it extends, improves and rationalizes the markup available for documents, and introduces markup and application programming interfaces (APIs) for complex web applications. For the same reasons, HTML 5 is also a candidate for cross-platform mobile applications, because it includes features designed with low-powered devices in mind.
Many new syntactic features are included. To natively include and handle multimedia and graphical content, the new
<canvas> elements were added, and support for scalable vector graphics (SVG) content and MathML for mathematical formulas. To enrich the semantic content of documents, new page structure elements such as
<figure> are added. New attributes are introduced, some elements and attributes have been removed, and others such as
<menu> have been changed, redefined, or standardized.
(HyperText Markup Language)
|Internet media type|
|Uniform Type Identifier (UTI)||public.html|
|Initial release||28 October 2014|
|Extended to||XHTML 5 (XML-serialized HTML 5)|
|Standard||HTML 5.2 Recommendation (W3C); HTML Living Standard (WHATWG)|
(XHTML Syntax of HTML 5)
|Internet media type|
|Developed by||World Wide Web Consortium and WHATWG|
|Type of format||Markup language|
|Extended from||XML, HTML 5|
|Standard||HTML 5.2 Recommendation: "The XHTML Syntax"|
The Web Hypertext Application Technology Working Group (WHATWG) began work on the new standard in 2004. At that time, HTML 4.01 had not been updated since 2000, and the World Wide Web Consortium (W3C) was focusing future developments on XHTML 2.0. In 2009, the W3C allowed the XHTML 2.0 Working Group's charter to expire and decided not to renew it.
The Mozilla Foundation and Opera Software presented a position paper at a World Wide Web Consortium (W3C) workshop in June 2004, focusing on developing technologies that are backward-compatible with existing browsers, including an initial draft specification of Web Forms 2.0. The workshop concluded with a vote—8 for, 14 against—for continuing work on HTML. Immediately after the workshop, WHATWG was formed to start work based upon that position paper, and a second draft, Web Applications 1.0, was also announced. The two specifications were later merged to form HTML 5. The HTML 5 specification was adopted as the starting point of the work of the new HTML working group of the W3C in 2007.
On 14 February 2011, the W3C extended the charter of its HTML Working Group with clear milestones for HTML 5. In May 2011, the working group advanced HTML 5 to "Last Call", an invitation to communities inside and outside W3C to confirm the technical soundness of the specification. The W3C developed a comprehensive test suite to achieve broad interoperability for the full specification by 2014, which was the target date for recommendation. In January 2011, the WHATWG renamed its "HTML5" specification HTML Living Standard. The W3C nevertheless continued its project to release HTML 5.
In July 2012, WHATWG and W3C decided on a degree of separation. W3C will continue the HTML 5 specification work, focusing on a single definitive standard, which is considered as a "snapshot" by WHATWG. The WHATWG organization continues its work with HTML 5 as a "living standard". The concept of a living standard is that it is never complete and is always being updated and improved. New features can be added but functionality will not be removed.
On 16 September 2014, W3C moved HTML 5 to Proposed Recommendation. On 28 October 2014, HTML 5 was released as a W3C Recommendation, bringing the specification process to completion. On 1 November 2016, HTML 5.1 was released as a W3C Recommendation. On 14 December 2017, HTML 5.2 was released as a W3C Recommendation.
The combined timelines for HTML 5.0, HTML 5.1 and HTML 5.2:
|Version||First draft||Candidate recommendation||Recommendation|
W3C and WHATWG have been characterized as both working together on the development of HTML 5, and yet also at cross purposes ever since the July 2012 split of the W3C work into milestone-based static standards and WHATWG's into a continually updated "living standard". The relationship has been described as "fragile", even a "rift", and characterized by "squabbling".
In at least one case, namely the permissible content of the
<cite> element, the two specifications directly contradict each other (as of July 2018), with the W3C definition being permissive and reflecting traditional use of the element since its introduction, but WHATWG limiting it to a single defined type of content (the title of the work cited). This is actually at odds with WHATWG's stated goals of ensuring backward compatibility and not losing prior functionality.
The "Introduction" section in the WHATWG spec (edited by Ian "Hixie" Hickson) is critical of W3C, e.g. "Note: Although we have asked them to stop doing so, the W3C also republishes some parts of this specification as separate documents." In its "History" subsection it portrays W3C as resistant to Hickson's and WHATWG's original HTML 5 plans, then jumping on the bandwagon belatedly (though Hickson was in control of the W3C HTML 5 spec, too). Regardless, it indicates a major philosophical divide between the organizations:
For a number of years, both groups then worked together. In 2011, however, the groups came to the conclusion that they had different goals: the W3C wanted to publish a "finished" version of "HTML5", while the WHATWG wanted to continue working on a Living Standard for HTML, continuously maintaining the specification rather than freezing it in a state with known problems, and adding new features as needed to evolve the platform.
Since then, the WHATWG has been working on this specification (amongst others), and the W3C has been copying fixes made by the WHATWG into their fork of the document (which also has other changes).
The "markets" for the two specifications are largely different. The W3C spec is the one that Web developers most often refer to, while the WHATWG version is used by the software development teams of the browser makers (though a version exists for Web content authors, trimmed of the material only of interest to browser coders). New features are added to HTML and, often experimentally, to browsers long before they appear in a W3C spec, because they arise in the WHATWG one. The technology journal Ars Technica observed that "both groups are likely to continue to exist, and both groups will continue to have broad-based industry backing".
In addition to the contradiction in the
<cite> element mentioned above, other differences between the two standards include at least the following, as of September 2018:
|Site pagination||Single page version (allows global search of contents)|
§10 Web workers
§11 Web storage
|Chapter Elements of HTML||§4.13 Custom elements|
||§220.127.116.11. Other pragma directives, based on deprecated WHATWG procedure.|
|§ Sections||§ 18.104.22.168 Sample outlines
§ 22.214.171.124 Exposing outlines to users
|Structured data||Recommends RDFa (code examples, separate specs, no special attributes).||Recommends Microdata (code examples, spec chapter, special attributes).|
The following table provides data from the Mozilla Development Network on compatibility with major browsers, as of September 2018, of HTML elements unique to one of the standards:
||W3C||All browsers, except Edge|
||W3C||None, except Firefox|
||WHATWG||All browsers||"[Since] the HTML outline algorithm is not implemented in any browsers ... the |
||WHATWG||Full support only in Edge and Firefox desktop.
Partial support in Firefox mobile.
Supported in Opera with user opt-in.
Not supported in other browsers.
||WHATWG||All browsers, except Edge and IE||Experimental technology|
The W3C proposed a greater reliance on modularity as a key part of the plan to make faster progress, meaning identifying specific features, either proposed or already existing in the spec, and advancing them as separate specifications. Some technologies that were originally defined in HTML 5 itself are now defined in separate specifications:
After the standardization of the HTML 5 specification in October 2014, the core vocabulary and features are being extended in four ways. Likewise, some features that were removed from the original HTML 5 specification have been standardized separately as modules, such as Microdata and Canvas. Technical specifications introduced as HTML 5 extensions such as Polyglot Markup have also been standardized as modules. Some W3C specifications that were originally separate specifications have been adapted as HTML 5 extensions or features, such as SVG. Some features that might have slowed down the standardization of HTML 5 will be standardized as upcoming specifications, instead. HTML 5.1 is expected to be finalized in 2016, and it is currently on the standardization track at the W3C.
HTML 5 introduces elements and attributes that reflect typical usage on modern websites. Some of them are semantic replacements for common uses of generic block (
<div>) and inline (
<span>) elements, for example
<nav> (website navigation block),
<footer> (usually referring to bottom of web page or to last lines of HTML code), or
<video> instead of
Some deprecated elements from HTML 4.01 have been dropped, including purely presentational elements such as
<center>, whose effects have long been superseded by the more capable Cascading Style Sheets. There is also a renewed emphasis on the importance of DOM scripting in Web behavior.
The HTML 5 syntax is no longer based on SGML despite the similarity of its markup. It has, however, been designed to be backward-compatible with common parsing of older versions of HTML. It comes with a new introductory line that looks like an SGML document type declaration,
<!DOCTYPE html>, which triggers the standards-compliant rendering mode.
Since 5 January 2009, HTML 5 also includes Web Forms 2.0, a previously separate WHATWG specification.
Not all of the above technologies are included in the W3C HTML 5 specification, though they are in the WHATWG HTML specification. Some related technologies, which are not part of either the W3C HTML 5 or the WHATWG HTML specification, are as follows. The W3C publishes specifications for these separately:
XML documents must be served with an XML Internet media type (often called "MIME type") such as
application/xml, and must conform to strict, well-formed syntax of XML. XHTML 5 is simply XML-serialized HTML 5 data (that is, HTML 5 constrained to XHTML's strict requirements, e.g., not having any unclosed tags), sent with one of XML media types. HTML that has been written to conform to both the HTML and XHTML specifications and which will therefore produce the same DOM tree whether parsed as HTML or XML is known as Polyglot markup
HTML 5 is designed so that old browsers can safely ignore new HTML 5 constructs. In contrast to HTML 4.01, the HTML 5 specification gives detailed rules for lexing and parsing, with the intent that compliant browsers will produce the same results when parsing incorrect syntax. Although HTML 5 now defines a consistent behavior for "tag soup" documents, those documents are not regarded as conforming to the HTML 5 standard.
According to a report released on 30 September 2011, 34 of the world's top 100 Web sites were using HTML 5 – the adoption led by search engines and social networks. Another report released in August 2013 has shown that 153 of the Fortune 500 U.S. companies implemented HTML5 on their corporate websites.
Since 2014, HTML 5 is at least partially supported by most popular layout engines.
The following is a cursory list of differences and some specific examples.
dates and times,
data-*(custom data attributes)
W3C Working Group publishes "HTML5 differences from HTML 4", which provides a complete outline of additions, removals and changes between HTML 5 and HTML 4.
On 18 January 2011, the W3C introduced a logo to represent the use of or interest in HTML 5. Unlike other badges previously issued by the W3C, it does not imply validity or conformance to a certain standard. As of 1 April 2011, this logo is official.
When initially presenting it to the public, the W3C announced the HTML 5 logo as a "general-purpose visual identity for a broad set of open web technologies, including HTML 5, CSS, SVG, WOFF, and others". Some web standard advocates, including The Web Standards Project, criticized that definition of "HTML5" as an umbrella term, pointing out the blurring of terminology and the potential for miscommunication. Three days later, the W3C responded to community feedback and changed the logo's definition, dropping the enumeration of related technologies. The W3C then said the logo "represents HTML5, the cornerstone for modern Web applications".
Industry players including the BBC, Google, Microsoft, Apple Inc. have been lobbying for the inclusion of Encrypted Media Extensions (EME), a form of digital rights management (DRM), into the HTML 5 standard. As of the end of 2012 and the beginning of 2013, 27 organisations including the Free Software Foundation have started a campaign against including digital rights management in the HTML 5 standard. However, in late September 2013, the W3C HTML Working Group decided that Encrypted Media Extensions, a form of DRM, was "in scope" and will potentially be included in the HTML 5.1 standard. WHATWG's "HTML Living Standard" continued to be developed without DRM-enabled proposals.
The initial enablers for DRM in HTML 5 were Google and Microsoft. Supporters also include Adobe. On 14 May 2014, Mozilla announced plans to support EME in Firefox, the last major browser to avoid DRM. Calling it "a difficult and uncomfortable step", Andreas Gal of Mozilla explained that future versions of Firefox would remain open source but ship with a sandbox designed to run a content decryption module developed by Adobe. While promising to "work on alternative solutions", Mozilla's Executive Chair Mitchell Baker stated that a refusal to implement EME would have accomplished little more than convincing many users to switch browsers. This decision was condemned by Cory Doctorow and the Free Software Foundation.
This document is obsolete.
Is this W3C's "official" logo for HTML5? Yes, as of 1 April 2011.
Adobe Flash is a deprecated multimedia software platform used for production of animations, rich Internet applications, desktop applications, mobile applications, mobile games and embedded web browser video players. Flash displays text, vector graphics and raster graphics to provide animations, video games and applications. It allows streaming of audio and video, and can capture mouse, keyboard, microphone and camera input. Related development platform Adobe AIR continues to be supported.
Artists may produce Flash graphics and animations using Adobe Animate. Software developers may produce applications and video games using Adobe Flash Builder, FlashDevelop, Flash Catalyst, or any text editor when used with the Apache Flex SDK.
End-users can view Flash content via Flash Player (for web browsers), AIR (for desktop or mobile apps) or third-party players such as Scaleform (for video games). Adobe Flash Player (supported on Microsoft Windows, macOS and Linux) enables end-users to view Flash content using web browsers. Adobe Flash Lite enabled viewing Flash content on older smartphones, but has been discontinued and superseded by Adobe AIR.
The ActionScript programming language allows the development of interactive animations, video games, web applications, desktop applications and mobile applications. Programmers can implement Flash software using an IDE such as Adobe Animate, Adobe Flash Builder, Adobe Director, FlashDevelop and Powerflasher FDT. Adobe AIR enables full-featured desktop and mobile applications to be developed with Flash and published for Windows, macOS, Android, iOS, Xbox One, PlayStation 4, Nintendo Wii U, and Switch.
Although Flash was previously a dominant platform for online multimedia content, it is slowly being abandoned as Adobe favors a transition to HTML5. Flash Player has been deprecated and has an official end-of-life at the end of 2020. However, Adobe will continue to develop Adobe AIR, a related technology for building stand-alone applications and games.Canvas element
The canvas element is part of HTML5 and allows for dynamic, scriptable rendering of 2D shapes and bitmap images. It is a low level, procedural model that updates a bitmap and does not have a built-in scene graph; however through WebGL allows 3D shapes and images and so-on.Comparison of browser engines (HTML support)
This article compares HTML support for several browser engines.
Support for the many new additions of the current HTML5 standard is in its own section after the items that preceded it in the history of HTML.Encrypted Media Extensions
Encrypted Media Extensions (EME) is a W3C specification for providing a communication channel between web browsers and digital rights management (DRM) agent software. This allows the use of HTML5 video to play back DRM-wrapped content such as streaming video services without the use of heavy third-party media plugins like Adobe Flash or Microsoft Silverlight. The use of a third-party key management system may be required, depending on whether the publisher chooses to scramble the keys.
EME is based on the HTML5 Media Source Extensions specification, which enables adaptive bitrate streaming in HTML5 using e.g. MPEG-DASH with MPEG-CENC protected content.EME has been highly controversial because it places a necessarily proprietary, closed component into what might otherwise be an entirely open and free software ecosystem. On July 6th, 2017, W3C publicly announced its intention to publish EME web standard, and did so on September 18th. On the same day, the Electronic Frontier Foundation published an open letter resigning from W3C.Google Chrome Experiments
Google Swiffy was a web-based tool developed by Google that converted SWF files to HTML5. Its main goal was to display Flash contents on devices that do not support Flash, such as iPhone, iPad, and Android Tablets. Swiffy was shut down July 1, 2016.HTML
HTML elements are the building blocks of HTML pages. With HTML constructs, images and other objects such as interactive forms may be embedded into the rendered page. HTML provides a means to create structured documents by denoting structural semantics for text such as headings, paragraphs, lists, links, quotes and other items. HTML elements are delineated by tags, written using angle brackets. Tags such as and directly introduce content into the page. Other tags such as
surround and provide information about document text and may include other tags as sub-elements. Browsers do not display the HTML tags, but use them to interpret the content of the page.
HTML5 Audio is a subject of the HTML5 specification, incorporating audio input, playback, and synthesis, as well as speech to text, in the browser.HTML5 in mobile devices
In mobile devices, HTML5 is often used for mobile websites and mobile applications on mobile operating systems such as Firefox OS, Sailfish OS, Tizen and Ubuntu Touch.HTML5 video
The HTML5 specification introduced the video element for the purpose of playing videos, partially replacing the object element. HTML5 video is intended by its creators to become the new standard way to show video on the web, instead of the previous de facto standard of using the proprietary Adobe Flash plugin, though early adoption was hampered by lack of agreement as to which video coding formats and audio coding formats should be supported in web browsers.HTML element
An HTML element is an individual component of an HTML (Hypertext Markup Language) document or web page. HTML is composed of a tree of HTML nodes, such as text nodes. Each node can have HTML attributes specified. Nodes can also have content, including other nodes and text. Many HTML nodes represent semantics, or meaning. For example, the
Netflix announced experimental support in June 2014 for the use of MSE playback on the Safari browser on the OS X Yosemite beta release.YouTube started using MSE with its HTML 5 player in September 2013.Microdata (HTML)
Microdata is a WHATWG HTML specification used to nest metadata within existing content on web pages. Search engines, web crawlers, and browsers can extract and process Microdata from a web page and use it to provide a richer browsing experience for users. Search engines benefit greatly from direct access to this structured data because it allows them to understand the information on web pages and provide more relevant results to users. Microdata uses a supporting vocabulary to describe an item and name-value pairs to assign values to its properties. Microdata is an attempt to provide a simpler way of annotating HTML elements with machine-readable tags than the similar approaches of using RDFa and microformats.
In 2013, because the W3C HTML Working Group failed to find someone to serve as an editor for the Microdata HTML specification, its development was terminated with a 'Note'. However, since that time, two new editors were selected, and five newer versions of the working draft have been published, the most recent being W3C Working Draft 26 April 2018.Rich web application
The Web Hypertext Application Technology Working Group (WHATWG) is a community of people interested in evolving HTML and related technologies. The WHATWG was founded by individuals from Apple Inc., the Mozilla Foundation and Opera Software, leading Web browser vendors, in 2004. Since then, the editor of the WHATWG specifications, Ian Hickson (originally with Opera), has moved to Google.
The central organizational membership and control of WHATWG today – its "Steering Group" – consists of Apple, Mozilla, Google, and Microsoft. WHATWG has a small, invitation-only oversight committee called "Members", which has the power to impeach the editor of the specifications. Anyone can participate as a "Contributor" by joining the WHATWG mailing list.WebM
WebM is an audiovisual media file format.
It is primarily intended to offer a royalty-free alternative to use in the HTML5 video and the HTML5 audio elements. It has a sister project WebP for images. The development of the format is sponsored by Google, and the corresponding software is distributed under a BSD license.
The WebM container is based on a profile of Matroska. WebM initially supported VP8 video and Vorbis audio streams. In 2013, it was updated to accommodate VP9 video and Opus audio.WebSocket
WebSocket is a computer communications protocol, providing full-duplex communication channels over a single TCP connection. The WebSocket protocol was standardized by the IETF as RFC 6455 in 2011, and the WebSocket API in Web IDL is being standardized by the W3C.
WebSocket is distinct from HTTP. Both protocols are located at layer 7 in the OSI model and depend on TCP at layer 4. Although they are different, RFC 6455 states that WebSocket "is designed to work over HTTP ports 80 and 443 as well as to support HTTP proxies and intermediaries," thus making it compatible with the HTTP protocol. To achieve compatibility, the WebSocket handshake uses the HTTP Upgrade header to change from the HTTP protocol to the WebSocket protocol.
The WebSocket protocol enables interaction between a web browser (or other client application) and a web server with lower overhead than half-duplex alternatives such as HTTP polling, facilitating real-time data transfer from and to the server. This is made possible by providing a standardized way for the server to send content to the client without being first requested by the client, and allowing messages to be passed back and forth while keeping the connection open. In this way, a two-way ongoing conversation can take place between the client and the server. The communications are done over TCP port number 80 (or 443 in the case of TLS-encrypted connections), which is of benefit for those environments which block non-web Internet connections using a firewall. Similar two-way browser-server communications have been achieved in non-standardized ways using stopgap technologies such as Comet.
Most browsers support the protocol, including Google Chrome, Microsoft Edge, Internet Explorer, Firefox, Safari and Opera.Web storage
Web storage, sometimes known as DOM storage (Document Object Model storage), provides web application software methods and protocols used for storing data in a web browser. Web storage supports persistent data storage, similar to cookies but with a greatly enhanced capacity and no information stored in the HTTP request header. There are two main web storage types: local storage and session storage, behaving similarly to persistent cookies and session cookies respectively.
All major browsers support Web storage, which is standardized by the World Wide Web Consortium (W3C).XHTML
eXtensible HyperText Markup Language (XHTML) is part of the family of XML markup languages. It mirrors or extends versions of the widely used HyperText Markup Language (HTML), the language in which Web pages are formulated.
While HTML, prior to HTML5, was defined as an application of Standard Generalized Markup Language (SGML), a flexible markup language framework, XHTML is an application of XML, a more restrictive subset of SGML. XHTML documents are well-formed and may therefore be parsed using standard XML parsers, unlike HTML, which requires a lenient HTML-specific parser.XHTML 1.0 became a World Wide Web Consortium (W3C) recommendation on January 26, 2000. XHTML 1.1 became a W3C recommendation on May 31, 2001. The standard known as XHTML5 is being developed as an XML adaptation of the HTML5 specification.