
613 So.2d 1266 (1993)
Ex parte Noble WILLIAMS and City of Phenix City, Alabama.
(Re Arthur SUMBRY v. Noble WILLIAMS and City of Phenix City, Alabama).
1920320.
Supreme Court of Alabama.
February 19, 1993.
*1267 James R. McKoon, Jr., Phenix City, for Noble Williams.
Charles E. Floyd, Phenix City, for City of Phenix City, Ala.
Albert O. Howard, Phenix City, for Arthur Sumbry.
INGRAM, Justice.
Noble Williams and the City of Phenix City petition this Court for a writ of mandamus directing the Circuit Court of Russell County to dismiss an election contest for lack of jurisdiction because Arthur Sumbry, the plaintiff in the contest, failed to "give good and sufficient security for the costs of the contest" within the time prescribed by law. See § 17-15-29, Ala. Code 1975.
We have held that mandamus is a drastic and extraordinary writ to be issued only where there is (1) a clear legal right in the petitioner to the order sought; (2) an imperative duty upon the respondent to perform, accompanied by a refusal to do so; (3) a lack of another adequate remedy; and (4) properly invoked jurisdiction of the court. Ex parte Martin, 598 So.2d 1381 (Ala.1992). We have also held that a petition for a writ of mandamus is the appropriate method to challenge the trial court's jurisdiction in an election contest. See Ex parte Shepherd, 172 Ala. 205, 55 So. 627 (1911).
Section 17-15-29, Ala.Code 1975, provides that one contesting an election for a municipal office must file a written statement of the grounds for the election contest and that this statement must be "verified by affidavit"; also, the contestant "must give good and sufficient security for the costs of the contest, to be approved by the clerk [of the circuit court]." This Court has held that the giving of such "good and sufficient security for the costs of the contest" is a jurisdictional requirement and that the security must be given within the time limits prescribed for the filing of an election contest. Dobbins v. City of Anniston, 469 So.2d 583, 585 (Ala. 1985); Bowen v. Holcombe, 204 Ala. 549, 550, 87 So. 87, 87 (1919). Sumbry challenges the results of an election for a municipal office; therefore, he was required to file his action and to give "good and sufficient security for the costs," within five days "after the result of the election is declared." See § 11-46-69(b), Ala.Code 1975.
According to the material furnished to this Court on the petition for the writ of mandamus, a municipal election was held in Phenix City on September 1, 1992, for the office of city councilman for district #3. Williams and Sumbry were candidates for the office, and Williams was declared the winner. Sumbry filed an election contest in the Circuit Court of Russell County on September 9, 1992. When Sumbry filed the contest, Sumbry avers, his attorney asked the circuit clerk what costs would be required. Sumbry alleges that the clerk told his attorney that he thought that the payment of the filing fee was sufficient.
On October 8, 1992, in response to a motion to dismiss filed by Williams and the City, the trial court ordered that Sumbry post a bond in an unlimited amount as security for the costs of the contest. The trial court stated in its order that the payment of the filing fee was sufficient compliance with § 17-15-29 to give the trial court jurisdiction to allow the "amendment" of the security for the costs required by § 17-15-29. Williams and the City filed this petition, seeking to compel the trial court to dismiss the election contest for lack of jurisdiction.
Although § 17-15-29 states that the clerk of the circuit court is to set the amount of the security for costs, this Court has held that failure to post security "in form at least," despite an attempt to timely post such security with the court clerk, is a jurisdictional defect and cannot be cured by a subsequent, untimely posting of security. Dobbins, 469 So.2d at 585 (circuit court clerk told the contestant that the trial court had to set the amount of the security, which is contrary § 17-15-29, and the contestant alleged that he could not timely *1268 reach the trial court). Therefore, the issue on this appeal is whether the payment of the required filing fee only is sufficient to constitute giving "good and sufficient security for the costs," for jurisdictional purposes.
"Security for costs" is defined as "[p]ayment into court in the form of cash, property or bond by a plaintiff ... to secure the payment of costs if such person does not prevail." Black's Law Dictionary 1357 (6th ed. 1990).
"The terms `fees' and `costs' are often used interchangeably as having the same application. Nevertheless, they are readily distinguishable, and each has a peculiar and appropriate meaning in law. Costs are allowances to a party for the expenses incurred in prosecuting or defending a suit, an incident to the judgment, while the fees are compensation to public officers for services rendered individuals, in the progress of the cause."
20 C.J.S. Costs § 3, at 11 (1990) (citing Troup v. Morgan County, 109 Ala. 162, 166, 19 So. 503, 504 (1896)).
Section 12-19-70(a) provides, "There shall be a consolidated civil filing fee, known as a docket fee, collected from a plaintiff at the time a complaint is filed in circuit court...." This fee, which apparently is what Sumbry paid, is the established charge for the service performed by the circuit clerk in docketing the cases filed. Obviously, a filing fee is the responsibility of a plaintiff; if a plaintiff is successful in his action, this filing fee may be taxed to the defendant in the action as "court costs." However, this filing fee is not an "expense" incurred by that defendant incident to his defense of the action filed in circuit court; on the contrary, the filing fee is an "expense" incurred by the plaintiff in prosecuting the action.
Moreover, the filing fee cannot constitute "security" for the defendants' costs, because such a fee is not available to the defendants, even if they successfully defend the action. The filing fee, as stated above, is payment for the services provided by the circuit clerk; therefore, that money, paid as a filing fee, is not available to the defendants to offset their expenses incurred in a successful defense of an election contest. According to § 12-19-72(3), Ala.Code 1975, the filing fee is distributed as follows: (1) $7 to the fair trial tax fund, (2) $93 to the state general fund, and (3) $10 to the county general fund. The filing fee must be paid whether or not the plaintiff is successful, unlike the defendants' costs, which the plaintiff must pay only if the defendants successfully defend the election contest.
Therefore, we hold that payment of the filing fee required by § 12-19-70 cannot be considered "good and sufficient security for the costs" in any form, because the filing fee does not represent a cost incident to the defense of the action and such money, paid as a filing fee, would not be available to pay Williams and Phenix City's costs if they were to successfully defend Sumbry's election contest. Because we hold that payment of the statutory filing fee cannot be considered "good and sufficient security for the costs," we must hold that Sumbry did not comply with the statute and, therefore, that the trial court was without jurisdiction.
The petition for the writ of mandamus is granted, and the Circuit Court of Russell County is ordered to dismiss this action for lack of jurisdiction.
WRIT GRANTED.
HORNSBY, C.J., and ALMON, SHORES, HOUSTON and STEAGALL, JJ., concur.
