text: Over a commutative ring, is a non-invertible matrix necessarily a zero divisor?
  
  I know that over a field, every non-invertible matrix is a zero divisor. Does the same hold for matrices over an arbitrary commutative ring?
  
  In the case of $1\times 1$ matrices, which are just elements of the ring, you are asking whether every non-unit in a ring must be a zero divisor. This is obviously false, for instance, in the ring $\mathbb{Z}$.
  
  • A good third of the questions we see here on matrices are answered by looking at 1-times-1 matrices ;-) – Mariano Suárez-Álvarez Jul 1 '17 at 20:02
  
  In $p$-adics any integer ending with $0$ is noninvertible, but a zero product requires a zero factor. Multiplication of two $p$-adic integers with only a finite number of total terminal zero digits gives a product with only that number of terminal zeroes.
  
  The determinant makes sense for matrices over a commutative ring $R$ and it's easy to prove that the square matrix $A$ is invertible if and only if $\det A$ is invertible in the base ring.
  
  On the other hand, if $d=\det A$ is not a zero divisor, then it becomes invertible in the full ring of quotients $Q(R)$ of $R$ (that is, $S^{-1}R$, where $S$ is the set of non zero divisors, which is a multiplicative set).
  
  Thus the matrix $A$ becomes invertible when seen (via the canonical map $\lambda\colon R\to Q(R)$) as a matrix with entries in $Q(R)$. If $A$ is a (left) zero divisor (over $R$), there exists a nonzero matrix $B$ with $AB=0$. However, the canonical map $\lambda$ is injective, so when we see these matrices over $Q(R)$ we have the same relation and invertibility of $A$ forces $B=0$: contradiction. The same if $A$ is a right zero divisor.
  
  Thus $A$ can be a zero divisor only if $\det A$ is a zero divisor in $R$ (including $0$, of course).