Build a polynomial that copies ex near x=0, one feature at a time. The constant 1 matches the height. 1+x also matches the slope: it is the tangent line. 1+x+2x2 also matches how fast the slope is changing. Each new term fixes one more derivative without spoiling the earlier ones, because xn and its first n−1 derivatives are all zero at x=0. At x=1 the partial sums run 1, 2, 2.5, 2.667, 2.708, 2.717, closing in on e≈2.71828.
The n! comes from differentiating. Taking three derivatives of x3 gives 3x2, then 6x, then 6=3!. So for the nth derivative of the term cn(x−a)n to equal f(n)(a), the coefficient has to be cn=n!f(n)(a). Forget the factorial and every term from x2 on is too big.
Matching derivatives at one point does not guarantee agreement far away. The series ln(1+x)=x−2x2+3x3−⋯ fits beautifully near 0, but at x=2 its terms n2n grow and the sum never settles, although ln3 is a perfectly good number. The series equals ln(1+x) only for −1<x≤1. A tangent line, by contrast, is the same idea stopped after two terms, and it is trustworthy only very close to a.
Think of it like this. A Taylor series is like giving directions from one landmark: first where you are (the value), then which way you are heading (the slope), then how the road bends (the second derivative), and so on. Near the landmark a few instructions get you almost exactly there. Far away the errors add up, and for some functions no amount of detail reaches past a certain distance.
Core idea. A Taylor series rebuilds a function as an infinite polynomial whose derivatives at a match the function's.