I'm trying to insert a picture besides the chapter title using this code

\chapter{for example}

but the picture is inserted in a new line. Can I specify a coordinate for inserting a picture there?

  • If you want the picture inside the caption, you don't want to float it. Therefore you do not want to use the figure environment. You may specify your image command directly into the \chapter{..}, though depending on the height it may look very odd. If you need more assistance please provide a MWE and probably a screenshot showing us your desired Output. Commented Jul 15, 2013 at 11:50
  • I get "use of chapter doesn't match its definition" if I try that.
    – JakobMST
    Commented Jul 15, 2013 at 12:05
  • Is this something that will be used for every chapter or just for some of them? Commented Jul 15, 2013 at 13:18

3 Answers 3


You can use TikZ; the tikzpagenodes gives you easy control on the positioning using the anchors for the text area:



\chapter{Test chapter}
\begin{tikzpicture}[remember picture,overlay]
\node[anchor=east,inner sep=0pt] at (current page text area.east|-0,3cm) {\includegraphics[height=3cm]{example-image-a}};



enter image description here

  • This does not work nicely in a multi column document. Commented Jan 5, 2023 at 16:12

If you specify a graphic in a chapter command, you will have to protect that command, so that it will not be interpreted when writing the toc file Or specify another heading:

\documentclass[12pt, a4paper]{report}


\chapter{looks odd in TOC \protect\includegraphics[width=20mm]{test.png}}
\chapter[does not look so odd in TOC (because the graphic is missing)]%
        {does not look so odd in TOC \includegraphics[width=20mm]{test.png}}


Since I'm getting complaints trying to include a graphic within the \chapter-command's argument, here's what worked for me:

This is more than anything a hack, But one thing you can do is to include the graphic in the next line and move it up with a negative \vspace. You can use any unit, but I believe it's best to use something like \baselineskip which is contextually defined rather than an absolute unit like mm or pt for the height of the vertical space. Be sure to include a positive \vspace afterwards to avoid squeezing the body of the chapter to the caption.

If you want to have a graphic to go with all your chapters, you can pack all of this into a macro which behaves like chapter except that it expects a second argument referencing a figure, like so:

\usepackage{graphicx, ifthen}

        \ifthenelse{\equal{#1}{\empty}}% check whether optional parameter is empty
        {\Huge %
           \vspace{-2.2\baselineskip} % move up
           \hfill % move graphic right
           \includegraphics[height=10mm]{#3} % include graphic
           \vspace{\baselineskip} % move down before body starts
        }% delimit scope of \Huge


\mychapter[toc title]{A chapter}{Logo-univie}%different title in TOC and heading

\mychapter{Another chapter}{Logo-univie}%same title everywhere

Some text

NOTE: Edited to preserve the optional argument of \chapter.

  • It should be noted, though, that neither this solution nor yours can handle really long chapter titles.
    – JakobMST
    Commented Jul 15, 2013 at 14:50

You must log in to answer this question.

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