I think your question lives most naturally in the category of ordered rings.

Here is one example: a field can be ordered iff it is formally real: i.e., iff -1 is *not* a sum of squares. However, more is true: if x is any element of a field K of characteristic different from 2 which is not a sum of squares, then there exists an ordering < on K in which x is negative. Thus any field which admits more than one ordering will have positive elements which are not sums of squares. For example, in Q(\sqrt{2}), with the usual convention, \sqrt{2} is positive, but it is not a sum of squares, because in a different ordering (here, an adjustment of the given ordering by a field automorphism!) it is negative.

Another Example: No, a positive definite rational or integral quadratic form need not be equivalent to a sum of squares. For instance the quadratic forms x^2 + y^2 and x^2 + 2y^2
are not equivalent over Q. For one thing, the discriminant of the quadratic form (= the product of the coefficients, for a diagonal quadratic form) is well-determined up to a square in the ground field. So it comes back to the fact that in R, every positive number is a square, but not in Q.

For matrices: look at the 1x1 case!

As was alluded to before, another case of this is Hilbert's 17th problem: let K be an ordered field with real closure R. (For simplicity just take K = R = real numbers!) Let f in K(x_1,..,x_n) be a rational function such that for all (a_1,...,a_n) in R^n at which f is defined, f(a_1,...,a_n) >= 0. Then there are rational functions g_1,l..,g_m in
K(x_1,...,x_n) such that f = g_1^2 + ... + g_m^2.