
450 So.2d 1279 (1984)
John PETTWAY, Petitioner,
v.
Louie L. WAINWRIGHT, As Secretary, Department of Corrections, Respondent.
No. AY-387.
District Court of Appeal of Florida, First District.
June 15, 1984.
John Pettway, petitioner, pro se.
Shirley A. Walker, Asst. Atty. Gen., Tallahassee, for respondent.
THOMPSON, Judge.
Pettway filed a "Petition for Judicial Review of Administrative Action" seeking review of action taken by the Department of Corrections (DOC) which denied him incentive gain-time during the last 45 days of his incarceration and thereby extended his incarceration by approximately 20 days. We treated this petition for review as a petition for writ of mandamus/habeas corpus and ordered the DOC to show cause why the petition should not be granted. After considering *1280 DOC's response and Pettway's reply thereto on May 24, 1984, we granted the petition for writ of habeas corpus and ordered the DOC to release Pettway. At that time we stated that this opinion would follow.
DOC contends that the grant of incentive gain-time is optional, not mandatory, because § 944.275(4)(b), Fla. Stat. (1983), states that the DOC "may" grant incentive gain-time. DOC therefore contends that under the statute it has discretion to award or not to award incentive gain-time. While it is true that the statute is not mandatory and the DOC may deny incentive gain-time, the DOC must uniformly grant or deny incentive gain-time unless there is some justification and authority for classifying and treating some prisoners different from other prisoners. The DOC argues that it needs a cut-off date for granting incentive gain-time in order to determine a definite release date sufficiently in advance of a prisoner's release and in order to properly prepare for the prisoner's release. While this might be a justifiable basis for adopting a rule authorizing such a procedure, no such rule has been adopted. Until the DOC adopts a rule in accordance with the Administrative Procedure Act and affected parties have had an opportunity to contest the validity of such a rule, the DOC is without authority to arbitrarily deny incentive gain-time to prisoners during their last month or more of incarceration.
ERVIN, C.J., and WIGGINTON, J., concur.
