
704 S.E.2d 173 (2010)
JOHNSON et al.
v.
RLI INSURANCE COMPANY.
No. S10G1027.
Supreme Court of Georgia.
November 22, 2010.
Albert L. Watson III, James D. Purple, Sr., for appellants.
Barrickman, Allred & Young, William S. Allred, Atlanta, Baker, Kinsman & Hollis, Norman M. Kinsman, Hawkins, Parnell, Thackston & Young, Christine L. Mast, Atlanta, Kennedy, Koontz & Farinash, Robert J. Wolford, Wargo & French, Windy A. Hillman, for appellee.
*174 CARLEY, Presiding Justice.
Tony Johnson and Mike Nichols, d/b/a J & N Holdings (Appellants), filed an action on April 29, 2008 seeking recovery for damages from several defendants, including RLI Insurance Company (Appellee), for violations of the Georgia RICO Act, bad faith, fraud, negligence, breach of legal duty, breach of contract, and punitive damages. On June 26, 2008, Appellee filed a motion to dismiss pursuant to OCGA § 9-11-12(b)(6). Both parties presented evidence to the court, including responses to interrogatories and affidavits. An oral hearing was held on January 8, 2009. On March 19, 2009, the trial court entered an order entitled "Order Granting RLI's Motion to Dismiss" and stated the following:
After hearing argument of counsel, considering the Plaintiffs' responses to Grange Insurance Company's Request for Admissions, Plaintiffs' response to Defendant RLI Insurance Company's Motion to Dismiss, Plaintiffs' answers to Gray Thacker's Interrogatories, the pleadings and the entire court record, . . . the motion to Dismiss. . . is hereby GRANTED.
Appellants appealed from this order directly to the Court of Appeals. Citing Johnson v. Hosp. Corp. of America, 192 Ga. App. 628, 629, 385 S.E.2d 731 (1989), the Court of Appeals, treating the trial court's order as a motion to dismiss, dismissed the appeal as premature because claims remained pending in the case, and, thus, the trial court's order was not a final judgment. Having granted certiorari to review this holding, we conclude that the language of OCGA § 9-11-12(b) requires a reviewing court to treat a motion to dismiss for failure to state a claim upon which relief can be granted as a motion for summary judgment if "matters outside the pleading are presented to and not excluded by the court."
In Thompson v. Avion Systems, 284 Ga. 15, 16-17, 663 S.E.2d 236 (2008), this Court set forth the procedure that a reviewing court must follow when complying with the mandate in OCGA § 9-11-12(b). On an appeal of a trial court's order that dismisses a cause of action for failure to state a claim upon which relief can be granted, "the reviewing court [must] determine whether either party has presented matters outside the pleading to the trial court[,] . . . [and if so] whether the trial court excluded . . . [or] considered such matters. . . . [Cits.]" Thompson v. Avion Systems, supra. Therefore, if matters outside the pleadings were presented to the trial court, which then considered these matters as it resolved the case, then a reviewing court is required to treat the resulting trial court's order as a ruling on a motion for summary judgment. See City of Demorest v. Town of Mount Airy, 282 Ga. 653, 654, fn. 1, 653 S.E.2d 43 (2007); Cox Enterprises v. Nix, 273 Ga. 152, 154, 538 S.E.2d 449 (2000); Hoffman v. PMC Development Co., 238 Ga. 258, 232 S.E.2d 541 (1977); Lamb v. Fulton-DeKalb Hosp. Auth., 297 Ga.App. 529, 532(1), 677 S.E.2d 328 (2009); Peeples v. City of Atlanta, 189 Ga.App. 888, 889(1), 377 S.E.2d 889 (1989).
In the present case, Appellee filed a motion to dismiss in the trial court pursuant to OCGA § 9-11-12(b)(6) alleging that the complaint filed by Appellants failed to state a claim upon which relief can be granted. There is no dispute that matters outside the pleadings were presented to the trial court. Also, the trial court explicitly stated in its order that it did not exclude these matters, but actually considered them. The trial court's order states that the motion to dismiss is granted after "considering the Plaintiffs' responses to Grange Insurance Company's Request for Admissions, Plaintiffs' response to Defendant RLI Insurance Company's Motion to Dismiss, Plaintiffs' answers to Gray Thacker's Interrogatories, the pleadings and the entire court record." Although the order of the trial court is entitled "Order Granting RLI's Motion to Dismiss," "the appealability of an order is determined, not by its form or the name given to it by the trial court, but rather by its substance and effect. [Cits.]" First Christ Holiness Church v. Owens Temple First Christ Holiness Church, 282 Ga. 883, 885, 655 S.E.2d 605 (2008). The trial court, by considering matters outside of the pleadings that were presented by the parties, in effect converted the motion to dismiss to a motion for summary judgment. Therefore, the *175 Court of Appeals erred by dismissing the direct appeal filed by Appellants, as the trial court's order should have been treated as an order granting summary judgment, thereby giving Appellants a right to a direct appeal pursuant to OCGA § 9-11-56(h).
Judgment reversed.
All the Justices concur.
