I know hyperref is a problematic package and there are many discussion on how to avoid potential problems.

However, in this small piece of code, I am not event loading any package, and yet, I get the option clash error for the hyperref package.

Can someone please help me figure out what the problem is? If I can get this one to work, I will try my main document with many packages!




\chapter{chapter one}
Figure \ref{fig1} shows ...

\caption{caption for figure one}


closed as too localized by doncherry, Speravir, Werner, morbusg, Thorsten Mar 1 '13 at 6:52

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center. If this question can be reworded to fit the rules in the help center, please edit the question.

  • I work in TexMaker and use PDFLatex to compile! Any idea why I am getting this error?! – Salman Mar 1 '13 at 1:09
  • I am copying this from my log file: This is pdfTeX, Version 3.1415926-2.3-1.40.12 (MiKTeX 2.9) (preloaded format=pdflatex 2012.10.11) – Salman Mar 1 '13 at 1:23
  • 1
    the actual version is Version 3.1415926-2.4-1.40.13 (MiKTeX 2.9) (preloaded format=pdflatex 2013.2.25). You should update ... – Mensch Mar 1 '13 at 1:34
  • 1
    @Salman Try deleting the auxiliary files and compiling again. – doncherry Mar 1 '13 at 2:01
  • 1
    @doncherry thank you! I got rid of the auxiliary files and they error went away! – Salman Mar 1 '13 at 2:43

The option clash error requires that the same package is loaded twice. The second time with at least one new option that was not given at the time, when the package was loaded first (LaTeX loads a package the first time, at subsequent loading requests it only checks the options).

Only one package is specified by the example file, thus the second load request has to be in an automatically loaded configuration file. Since option colorlinks is not given, the only configuration file is hyperref.cfg. Perhaps you are using \usepackage[...]{hyperref} there to set some options. That's pointless, LaTeX does not load the package twice. Use \hypersetup instead.

Not the answer you're looking for? Browse other questions tagged or ask your own question.