I have a problem because when I add labels to equations (Pic.1), they appear in the margins of the text (Pic.2). If I do not add a label it gets a question mark in the margin. Unfortunately the Overleaf documentation does not solve my problem.

Thanks for everything. Draqun


enter image description here


enter image description here


\documentclass{MastersDoctoralThesis} % The class file specifying the document structure

\begin{equation} \label{eq:thread}
    T_{P} = \{t_i|i=0...\alpha\}, \alpha \in \mathbb{N}



\ProvidesClass{\classname}[2017/08/27 v1.6 LaTeXTemplates.com]




\usepackage[utf8]{inputenc} % Required for inputting international characters
\usepackage[T1]{fontenc} % Output font encoding for international characters
\usepackage{mathpazo} % Use the Palatino font by default
  • 2
    Did you try running it more than once? The second run should resolve the ? issue. Also, instead of an image, it is always better to provide a fully compilable MWE that illustrates the problem including the \documentclass and the appropriate packages so that those trying to help don't have to recreate it. Feb 4, 2022 at 18:51
  • 3
    ...and you probably have a package like showlabel or showkeys loaded. Please read tex.meta.stackexchange.com/questions/6255/…
    – Rmano
    Feb 4, 2022 at 18:52
  • 3
    Now we can only guess, what is going on in your document. Please provide code for complete small document, which we can test as it is and which reproduce your problem
    – Zarko
    Feb 4, 2022 at 19:05
  • 1
    \label does not make any printed output it is just an internal identifier for use with \ref you wil have shokabel or similar debug package loaded to make the internal label visible. But please do not post code as an image it makes it hard for anyone to debug it for you, Feb 4, 2022 at 20:29
  • 1
    That was enough for an answer. For future reference, you could also trim the class file quite a bit more. That might have been enough for you to narrow the problem down to refcheck.
    – Teepeemm
    Feb 5, 2022 at 19:58

1 Answer 1


Your class is loading the package refcheck. By default, that package will print the labels in the margins. If you don't have a reference to that label in your document, it will also include the ? (and add a warning to the log file). To disable both the ? and the label printing, add the command \norefnames to your preamble before the \begin{document}.

  • Right. I forgot about refcheck. Thanks a lot!!! Best regards.
    – Draqun
    Feb 7, 2022 at 16:22

You must log in to answer this question.

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