5. Let $f(x)$ be a polynomial of degree 2014, such that
$$
f(k)=\frac{1}{k}(k=1,2, \cdots, 2015) \text {. }
$$

Then $f(2016)=$ $\qquad$
5. $\frac{1}{1008}$.

Construct the function $g(x)=x f(x)-1$.
Then $g(1)=g(2)=\cdots=g(2015)=0$.
Thus, $g(x)=a(x-1)(x-2) \cdots(x-2015)$, where $a$ is an undetermined constant in $g(x)$.
$$
\begin{array}{l}
\text { By } f(x)=\frac{g(x)+1}{x} \\
=\frac{a(x-1)(x-2) \cdots(x-2015)+1}{x}
\end{array}
$$

is a polynomial of degree 2014, so
$$
a(x-1)(x-2) \cdots(x-2015)+1
$$

must have a constant term of 0.
Thus, $-2015!a+1=0 \Rightarrow a=\frac{1}{2015!}$.
Therefore, $f(2016)=\frac{1+1}{2016}=\frac{1}{1008}$.