If a derivative of a continuous function has a limit, must it agree with that limit? [duplicate]

For the limit to make sense, we have to assume that $f'$ exists on some interval around $c$.

If $\lim_{x\to c}f'(x)=L$, then $f'(c)$ exists and it is equal to $L$. Indeed, using the Mean Value Theorem we have $$ \frac{f(c+h)-f(c)}h=f'(\xi(h)) $$ for $\xi(h)$ between $c$ and $c+h$. As $h\to0$, $c+h\to c$ and so $\xi(h)\to c$. So $$ \lim_{h\to 0}\frac{f(c+h)-f(c)}h=\lim_{h\to0}f'(\xi(h))=L. $$


For a quicker proof, use L'Hopital's rule

$$\lim_{x\to a}\frac{f(x)-f(a)}{x-a}=\lim_{x\to a}\frac{f'(x)}{1}=\lim_{x\to a}f'(x)$$