I am looking for a filled version of \hexagon.

I found \Steelhexagon from "marvosym", but in the template that I am using it seems to render as an arrow and I get conflicts because of other symbols in "marvosym". I wonder if there is a black hexagon symbol in a more common latex package.

  • 1
    As always on the site please provide a full (but minimal) example that others can copy and test as is. Otherwise we cannot help much. Also note that there are a lot of bad templates out there.
    – daleif
    Jul 10, 2020 at 13:44

6 Answers 6


As for most unicode symbols, there are filled hexagons in the STIX font.

They can be imported without importing the whole font.

\DeclareMathSymbol{\hexagonblack}   {\mathord}{symbols4}{"DE}
\verb|\hexagonblack|: \( \hexagonblack \)

\verb|\varhexagonblack|: \( \varhexagonblack \)
  • How did you calculate the DD and DE? I the stix documentation I see four hexdigit codes and they seem to have nothing to do with the codes in your snippet.
    – allo
    Jul 31, 2020 at 8:41
  • 1
    @allo The four hexdigit codes you see in the documentation are the codes of the unicode symbols, and are not directly related to the font. To find the location of the symbols in the font (by that I mean these "DD and "DE codes), you can look in the file stix.sty, and search for the line defining the symbol you're looking for. You should find a line \DeclareMathSymbol... like those in my answer.
    – Vincent
    Jul 31, 2020 at 14:15

Just it is a bit complex but I had used thus how I have written in the image a combination between tikz and \usetikzlibrary{shapes} that get the hexagon symbol: regular polygon sides=6. After I have used \mathord like suggested by user @Thruston in the recent comment.


\newcommand{\bhexagon}{\mathord{\raisebox{0.6pt}{\tikz{\node[draw,scale=.65,regular polygon, regular polygon sides=6,fill=black](){};}}}}

\verb|tikz package with shapes|

enter image description here

Remember that STIX font change also the font of the text. Thus with the previous code you have always (for example) the font computer modern with the default symbol of amssymb.

ADDENDUM: It is possibile to have another hexagon symbol with the package oplotsymbl (using graphicx+rotatebox you can have the classic hexagon):

enter image description here

Another option

ADDENDUM 2: Now I have seen that exist also a new package called dbnsymb rev. 7 Mar. 2, 2020 that it give us also the symbol \hexagon. It is important to have dbnsymb.sty to use this package.

enter image description here

I think that using xcolor package this symbol can be coloured.

ADDENDUM 3: Surely you can directly to use the symbol using XeLaTeX or LuaLaTeX (Unicode characters) with fontspec:

Symbol, Title/Description   Unicode Code / HTML Code

⬢, Black Hexagon, ⬢ ⬢

⬣, Horizontal, Black Hexagon, ⬣ ⬣

ADDENDUM 4: using unicode-math + XITS Math

\setmathfont{XITS Math}

First $\hb+\vbh=\triangle$ second

enter image description here

  • 2
    Would it be better to use \mathord instead of \mathbin here?
    – Thruston
    Jul 11, 2020 at 12:47
  • @Thruston I have edited my MWE: Thank you very much for your feedback.
    – Sebastiano
    Jul 11, 2020 at 15:25
  • 1
    Hello Sebastiano!! Amazing result, congrats 👏.
    – manooooh
    Jul 11, 2020 at 17:39
  • 1
    @manooooh Weeeeeeeeeeeeeeeeeee ahahhahah 👀👀👀. Always kind with me.
    – Sebastiano
    Jul 11, 2020 at 18:52

The STIX font also has two versions of the symbol (in different rotations). For pdfLaTeX you can use the stix2 package. Downside is that STIX becomes the font for your entire document.



enter image description here


You can print this symbol without any package from the font MarVoSym.ttf:



The symbols in marvosym are meant to be used in text.



Wrong: \verb|$a=\HexaSteel$| $\to$ $a=\HexaSteel$

Right: \verb|$a=\text{\HexaSteel}$| $\to$ $a=\text{\HexaSteel}$


Of course, if you plan to use this as a math symbol, you can do


in your document preamble.

enter image description here


The unicode-math package includes all the math symbols in Unicode, under the same names as stix and stix2. You can import them with

\setmathfont[ range={\hexagonblack,\varhexagonblack},
            ]{STIX Two Math}

XITS Math is a fork of the STIX 1 font, and other fonts might or might not have these symbols.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .