I am currently writing a report for my internship on LaTeX. I am using TeXstudio since my file was becoming too large for free Overleaf to compile. I have many referencing in it, and I would like to change their colour to blue. I used the command below (I specified everything since I was trying to fix this), and my in-text references are indeed appearing blue (like "Fig.x" when citing a figure or "[x]" when citing an article) but my issue is that my TOC also appears blue. I found out that it was the "linkcolor=" controlling that but setting it to black also set my figures/part referencing to black as well. Is there a way to have these references blue, while keeping my TOC black? Thanks in advance.


1 Answer 1


You need to compile twice after adding like here \addtocontents{toc}{\protect\hypersetup{hidelinks}} right after \begin{document}.



  • Ah thank you so much it worked!
    – Alexis L.
    Commented Jul 10 at 8:47

You must log in to answer this question.

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