When $R/J(R)$ is indecomposable Let $R$ be a commutative ring with 1, and let $J(R)$ be the Jacobson radical of $R$, that is, the intersection of all maximal ideals of $R$.  Is there any equivalent conditions under which $R$ and $R/J(R)$ be two indecomposable rings?
 A: In general being indecomposable is equivalent to having no nontrivial idempotents.
Thus one condition is that $R$ and $J(R)$ have no nontrivial idempotents. However we can do better.

If $R/J(R)$ is indecomposable, then $R$ is indecomposable.

Proof:
We prove the contrapositive, if $R$ decomposes, then $R/J(R)$ does.
Let $e$ be a nontrivial idempotent in $R$. $1-e$ is also a nontrivial idempotent, and $e$ and $1-e$ are both nonunits. Therefore both are contained in maximal ideals, but they cannot be contained in the same maximal ideal, since then $1=e+(1-e)$ would lie in the maximal ideal. $e,1-e \not \in J(R)$, so $e\not\equiv 1,0 \pmod{J(R)}$. Hence a nontrivial idempotent descends to a nontrivial idempotent in $R/J(R)$. $\blacksquare$
Under slightly stronger assumptions (slightly stronger in the sense that they often hold for rings that are cared about in algebraic geometry) we can show that $R$ indecomposable implies $R/J(R)$ indecomposable.

Let $R$ be an SBI ring. Then $R$ is indecomposable if and only if $R/J(R)$ is. (Credit to rschwieb for broadening the hypotheses from my original statement, I had not heard of SBI rings before.)

By definition an SBI ring is one where idempotents in $R/J(R)$ lift to $R$. I.e. if $e$ is idempotent in $R/J(R)$, then there exists an idempotent $f$ in $R$ with $e=f+J(R)$. 
Proof:
It suffices to show that if $R/J(R)$ has a nontrivial idempotent then $R$ does, but that is immediate from the definition of an SBI ring, so we are done. $\blacksquare$
The natural question then is: What rings are SBI?
Any ring with $J(R)=\sqrt{0}$ is SBI. We have idempotent lifting over any ideal consisting of nilpotent elements. See rschwieb's proof here (note that the question assumes that the ideal is nilpotent, but the proof only uses that the ideal consists of nilpotent elements. I only point it out because these concepts aren't necessarily the same for non-Noetherian rings, so the proof gives a stronger result than asked for in the question).
In particular, this includes Jacobson rings, which themselves include many important rings from algebraic geometry, fields, Dedekind domains with infinitely many primes, and finitely generated algebras over other Jacobson rings.
Local rings are also SBI, though sort of trivially so, since $J(R)=\mathfrak{m}$ the maximal ideal of the local ring in this case, and $R/J(R)$ is a field and thus has no nontrivial idempotents.
