To find the value of the function \( y = 3x^2 - 21 \) when \( x = 4 \), we substitute \( 4 \) for \( x \):
\[ y = 3(4)^2 - 21 \]
Calculating \( (4)^2 \):
\[ (4)^2 = 16 \]
Now substitute back into the equation:
\[ y = 3(16) - 21 \]
Calculating \( 3(16) \):
\[ 3(16) = 48 \]
Now substituting that back:
\[ y = 48 - 21 \]
Calculating \( 48 - 21 \):
\[ y = 27 \]
Thus, the value of the function when \( x = 4 \) is
\[ \boxed{27} \]