Unlike the Jews, the Romans were not limited to 39 stripes, so the beating Paul and Silas took was severe. The stocks they had to endure afterward were two large pieces of wood pierced with holes at different distances, designed to restrain the feet and produce pain.
Confined to the pitch-dark bowels of the prison, Paul and Silas now lie on a filthy floor on their bloody, shredded backs, their legs painfully distended. One might think they would have every right to complain about how unfairly the Philippians had treated them—or at least to spend all their time beseeching God to relieve them of their pain. Notice verse 25, however: "But at midnight Paul and Silas were praying and singing hymns to God, and the prisoners were listening to them"!
Not only were they singing praises of thanksgiving to God, but they were also doing it loud enough for the other prisoners to hear them! Just as James says in James 5:13: "Is anyone among you suffering? Let him pray. Is anyone cheerful? Let him sing psalms." They were praying for their affliction, but they were also singing songs of praise to God from hearts filled with thanksgiving!
Are we willing to do this, or will we just thank God when we think He deserves it? We need to make it a sincere habit to thank God fervently every day for all His benefits, glorifying His holy will and purpose for us. He is never undeserving of our praise and thanks—indeed, we cannot thank Him enough.