We determine the stability condition of low-density parity-check codes under both bitwise and blockwise maximum a posteriori decoding. As a consequence, we prove that the stability condition determines an upper bound on both the bitwise and the blockwise maximum a posteriori threshold.