The local extrema of a function occur at points where the first derivative of the function is 0 and the sign of the first derivative changes.
That is, for x where f'(x) = 0 and either f'(x-varepsilon) <= 0 and f'(x+varepsilon) >= 0 (local minimum) or
f'(x-varepsilon) >= 0 and f'(x+varepsilon) <= 0 (local maximum)
To find the local extrema, then, we need to find the points where f'(x) = 0.
f'(x) = 3x^2 - 3 = 3(x^2 - 1) = 3(x+1)(x-1)
so
f'(x) = 0 <=> 3(x+1)(x-1) = 0 <=> x=+-1
Looking at the sign of f' we get
{(f'(x) > 0 if x < -1), (f'(x) < 0 if -1 < x < 1), (f'(x) > 0 if x > 1):}
So the sign of f' changes at each of x = -1 and x = 1 meaning there is a local extremum at both points.
Note: From the change in signs, we can further tell that there is a local maximum at x = -1 and a local minimum at x = 1.