  Consider a nonlinear wave equation for a massless scalar field with
self-interaction in the spatially flat Friedmann-Lema\^{i}tre-Robertson-Walker
spacetimes. For the case of accelerated expansion, we show that blow-up in a
finite time occurs for the equation with arbitrary power nonlinearity as well
as upper bounds of the lifespan of blow-up solutions. Comparing to the case of
the Minkowski spacetime, we discuss how the scale factor affects the lifespan
of blow-up solutions of the equation.
