
399 So.2d 122 (1981)
FLORIDA ROCK AND TANK LINES, INC. and Florida Rock Industries, Inc., Appellants,
v.
The CONTINENTAL INSURANCE COMPANY, Appellee.
No. SS-510.
District Court of Appeal of Florida, First District.
June 3, 1981.
B. Thomas Whitefield of Ulmer, Murchison, Ashby & Ball, Jacksonville, for appellants.
Carle A. Felton, Jr. of Boyd, Jenerette, Leemis & Staas, P.A., Jacksonville, for appellee.
*123 McCORD, Judge.
Florida Rock and Tank Lines, Inc. (formerly Diamond Sand and Stone) and Florida Rock Industries, Inc., appeal from an order of the trial court striking their claim for attorney's fees, made pursuant to § 627.428(1), Florida Statutes (1979).[1] We reverse.
Appellants were defendants in an indemnity action brought by their insurer, Continental. In its complaint, Continental asserted, inter alia, that under the terms of the insurance policy and/or an endorsement which allegedly became a part thereof, appellants were required to reimburse Continental for monies it expended in the defense and settlement of certain claims arising out of an accident involving one of appellants' trucks.
Appellants defended by denying the pertinent allegations of the complaint, including a specific denial that the alleged endorsement ever became part of the contract; and by affirmatively asserting, inter alia, that by its conduct, Continental was estopped from claiming and/or had waived any right to reimbursement, that Continental was collaterally estopped by virtue of prior litigation, etc.
Pursuant to a jury verdict, the trial court entered final judgment in favor of appellants, reserving jurisdiction for purposes of determining appellants' right to recover attorney's fees. Continental thereafter filed a Motion to Strike the claim for attorney's fees, which motion was granted by the trial court.
In refusing to award appellants' attorney's fees, the trial court stated:
Under a strict construction of said statute [Section 627.428] it appears that attorneys fees should be awardable to an insured only in those cases where the insured is the "prosecuting" party and a judgment has been entered in favor of the insured and against the insurance company on litigation instituted by the assured. The Court further finds and rules that the intent of the statute providing for attorneys fees is to safeguard the insured and to penalize the insurance company when the insurance company has wrongfully denied coverage or has wrongfully refused to defend under the provisions of the insurance contract, thus placing the insured in a precarious position. In this case the litigation was instituted by the insurance company; no coverage question was presented; the insurance company had defended claims asserted by third party claimants against the insured in prior litigation and had not denied coverage; and this suit was solely concerned with the insurance company's claim for reimbursement under the provisions of an endorsement which allegedly was issued and became part of the policy of insurance.
Contrary to the trial court's findings, the phrase "prosecuting the suit" contained in the statute, does not require that the insured have instituted the suit against the insurance company. Peninsular Life Insurance Co. v. Howard, 72 So.2d 389 (Fla. 1954); Old Republic Insurance Co. v. Monsees, 188 So.2d 893 (Fla. 4th DCA 1966). The statute is likewise applicable when the insured successfully defends an action brought by the insurance company. Roberts v. Carter, 350 So.2d 78, 79 n. 6 (Fla. 1977); Monsees, supra.
Further, the fact that Continental had defended the claims and had not denied coverage does not preclude application of the statute. James Furniture Manufacturing Co., Inc. v. Maryland Casualty Company, 114 So.2d 722 (Fla. 3rd DCA 1959), disapproved on other grounds, Roberts v. Carter, 350 So.2d 78, 79 n. 6 (Fla. 1977). Finally, *124 the finding that no "coverage question" was presented is not determinative of the issue of attorney's fees. The purpose of the statute is to discourage the "contesting" of insurance policies and to reimburse successful insureds reasonably for their outlays for attorney's fees, when they are compelled to defend or sue to enforce their contracts. Wilder v. Wright, 269 So.2d 434, 436 (Fla.2d DCA 1972), quoted with approval on affirmance, 278 So.2d 1, 3 (Fla. 1973). Here, a bona fide controversy existed as to the rights and obligations of the parties under the contract of insurance. The statute does not require that the contested issue be that of coverage. Gulf Life Insurance Co. v. Urquiaga, 251 So.2d 904 (Fla.2d DCA 1971). See also Travelers Insurance Company v. Horton, 366 So.2d 1204 (Fla. 3rd DCA 1979).
Continental brought the present action alleging that under a contract of insurance executed by the insurer, it was entitled to reimbursement. Appellants successfully defended this suit and received a judgment against the insurer and in favor of the insureds. Thus, all the requirements of § 627.428 have been met and appellants are entitled to a reasonable sum as attorney's fees.
The order of the trial court striking appellants' claim for attorney's fees is REVERSED and this cause is REMANDED to the trial court with directions to enter an order in accordance herewith.
SHIVERS and JOANOS, JJ., concur.
NOTES
[1]  627.428 Attorney fee. 

(1) Upon the rendition of a judgment or decree by any of the courts of this state against an insurer and in favor of an insured or the named beneficiary under a policy or contract executed by the insurer, the trial court, or, in the event of an appeal in which the insured or beneficiary prevails, the appellate court, shall adjudge or decree against the insurer and in favor of the insured or beneficiary a reasonable sum as fees or compensation for the insured's or beneficiary's attorney prosecuting the suit in which the recovery is had.
