# Error in \title : Overleaf

I am using Overleaf and am receiving the following error when I try setting the title to my file.

Illegal parameter number in definition of \@title. <to be read again> 1

How should I fix this ?

• Welcome to TeX.SX. Please provide a MWE of your problem. Without one it is nearly impossible to help you. – Benjamin Jan 31 '16 at 2:16
• Correct the definition of \@title so that it no longer uses an illegal parameter number? Usually this means you have #1 when you want ##1 or ##1 when you want ###1 or ##1 when your want #1 or ###1 when you want ##1 or ... Or else it means that you've tried to use something like #1 in a macro which was not defined to absorb any arguments at all. However, that is less likely in this case as it is a standard macro. If you don't think you've redefined it at all, do you have a literal hash symbol in \title{} or something? – cfr Jan 31 '16 at 3:01
• @cfr : Yes, I have a hash symbol in my title : \title{#1} – stark Jan 31 '16 at 3:46
• That's the problem, then. Is your paper really titled #1? No offence intended: I'm sure there's an audience out there for that kind of thing. Just not my cup of tea, probably. – cfr Jan 31 '16 at 4:00
• @cfr : No, my paper is not just titled #1, there was some text before it in the title but I didn't post it here since I thought the text wasn't relevant to the error. – stark Jan 31 '16 at 4:01

A # is a special character. TeX assumes you mean to use it to refer to an argument parameter. If you wish to literally typeset a hash symbol, you must escape the character or otherwise request it indirectly.

For example:

\documentclass{article}
\title{A \# to end all \# s}
\author{S. O. M. E. Body}
\begin{document}
\maketitle
\end{document}


• Perfect, that fixed it. I was not aware of # being a special character. Thanks. – stark Jan 31 '16 at 3:59