As the friend @Maujor commented, the tag <hgroup>
is deprecated link
But as a complement I would like to leave a more semantic and updated solution using the <header>
tag.
According to W3C:
A header
element is intended to usually contain the section's heading (an h1–h6
element), but this is not required. The header element can also be used to wrap a section's table of contents, a search form, or any relevant logos.
Translating:
The
header
element can also be used to group the index of a section, but this is not necessary. The
h1 – h6
element can also be used to group the index of a section, a search form or any relevant logo. "
Source: link
Basic example:
<header>
<h1>Welcome to...</h1>
<h2>StackOverflow!</h2>
</header>