Jim McElwain has agreed to leave Colorado State to become the next head coach at Florida.

The deal had been hung up before Thursday morning as Colorado State refused to budge on McElwain's $7.5 million buyout and Florida had refused to pay the entire amount. It is unclear at this point if Florida agreed to pay the full buyout amount or if the schools settled on a smaller amount.

McElwain was in his third season at Colorado State. The Rams (10-2) have won 16 of their last 20 games dating to last season. That's after losing 27 of 36 games in the three seasons prior to McElwain's arrival in 2012.

Originally from Montana, McElwain tutored first-year starting quarterbacks (Greg McElroy and AJ McCarron) in two of his four seasons as Alabama's offensive coordinator. The Crimson Tide were known for their offensive balance under McElwain.