Package pgfkeys Error: I do not know the key '/tikz/<key>' and I am going to ignore it. Perhaps you misspelled it.
A TikZ option is misspelled, is a color that was never defined, or belongs to a TikZ library that is not loaded with \usetikzlibrary.
Help centre › LaTeX errors › Commands and packages · Error: the build stops or the output is wrong
What the log says
! Package pgfkeys Error: I do not know the key '/tikz/thik' and I am going to ignore it. Perhaps you misspelled it.
See the pgfkeys package documentation for explanation.
l.5 \draw[->, thik] (0,0) -- (2,0);Also printed as: Package pgfkeys Error: I do not know the key '/tikz/<key>'
What it means
Everything in the square brackets of a TikZ command is a key, looked up under /tikz/. This one is not defined, so TikZ ignores it and carries on; the drawing comes out without that style. TikZ also tries an unknown single word as a color name, so an undefined color ends up here too.
Causes and fixes
Most common first. Each example is a complete document; the first fails with this message, the second is the same document fixed.
1. The option is misspelled
Check the spelling against the TikZ manual: thick, dashed, rounded corners, minimum width. Keys use spaces, not hyphens or camel case.
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\draw[->, thik] (0,0) -- (2,0);
\end{tikzpicture}
\end{document}\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\draw[->, thick] (0,0) -- (2,0);
\end{tikzpicture}
\end{document}2. A color name that has not been defined
A bare word in the options is tried as a color. Define it in the preamble, for example \definecolor{paperblue}{RGB}{31,90,166}, or use a predefined name such as blue.
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\draw[paperblue, thick] (0,0) circle (1);
\end{tikzpicture}
\end{document}\documentclass{article}
\usepackage{tikz}
\definecolor{paperblue}{RGB}{31,90,166}
\begin{document}
\begin{tikzpicture}
\draw[paperblue, thick] (0,0) circle (1);
\end{tikzpicture}
\end{document}3. The key belongs to a TikZ library that is not loaded
Many keys come from libraries: drop shadow needs shadows, below=of and on grid need positioning, decorate styles need decorations.pathmorphing. Add \usetikzlibrary{…} to the preamble.
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\node[draw, fill=white, drop shadow] {Input};
\end{tikzpicture}
\end{document}\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{shadows}
\begin{document}
\begin{tikzpicture}
\node[draw, fill=white, drop shadow] {Input};
\end{tikzpicture}
\end{document}4. A pgfplots option used in a plain tikzpicture
Keys such as xlabel, ymin or grid=major belong to an axis environment from pgfplots, not to \draw or tikzpicture. Put them in \begin{axis}[…].
In Manulyx
The editor shows the error beside the line with an explanation, including the colour case: if the word is meant to be a colour, define it in the preamble.
Write in Manulyx for free · Journal templates
More in commands and packages
- Undefined control sequence.LaTeX met a command it does not know: usually a typo, or a command whose package is not loaded. The log's l. line ends with the culprit.
- Missing number, treated as zero.A command that needs a number or length (\vspace, \setcounter, a width) got a word or nothing. Give it a value such as 1em or 3.
- LaTeX Error: Command \<name> already defined.\newcommand or a package tried to define a name that already exists. Pick another name, use \renewcommand, or drop the clashing package.
- Illegal parameter number in definition of \<name>.A # in a definition does not refer to a declared argument: #1 without [1], #1 in an environment's end code, or a # in a URL. Fix the count or escape it.
- Use of \<name> doesn't match its definition.A command with a special argument syntax, such as \put(x,y) or a \def with delimiters, was called without that syntax. Follow its exact form.
- LaTeX Error: Environment <name> undefined\begin{…} names an environment no loaded package defines: load the package (amsmath for align), fix the spelling, or define it with \newtheorem.
Every example on this page was compiled with pdfLaTeX to check that it fails and is fixed as described. All LaTeX errors