We report a measurement of D0-D¯0 mixing parameters and a search for indirect CP violation through a time-dependent amplitude analysis of D0→KS0π+π- decays. The results are based on 921 fb−1 of data accumulated with the Belle detector at the KEKB asymmetric-energy e+e- collider. Assuming CP conservation, we measure the mixing parameters x=(0.56±0.19-0.09-0.09+0.03+0.06)% and y=(0.30±0.15-0.05-0.06+0.04+0.03)%, where the errors are statistical, experimental systematic, and systematic due to the amplitude model, respectively. With CP violation allowed, the parameters |q/p|=0.90-0.15-0.04-0.05+0.16+0.05+0.06 and arg(q/p)=(-6±11±3-4+3)° are found to be consistent with conservation of CP symmetry in mixing and in the interference between mixing and decay, respectively.