Joshua Snyder, proceeding pro se, appeals the order of the Court of Common Pleas of Blair County “declining to consider” his petition for writ of habeas corpus.
Snyder’s petition for habeas corpus named Frank Gillis, Superintendent of the State Correctional Institution at Coal Township, and William Ward, Chairman of the Pennsylvania Board of Probation and Parole, as respondents, and it essentially averred that the Board and corrections staff, violated his constitutional rights in connection with denying him re-parole in April 2001 and March 2002. Snyder did not file the petition under his Blair County criminal docket numbers, and we can discern no reason for the trial court’s decision not to give the matter a new number that would preserve the caption under which it was actually filed.
The trial court “declined to consider” the petition after concluding that the issues raised were not within its jurisdiction. (Trial court order dated 7-23-02.) Snyder filed a notice of appeal, and at this Court’s direction, the trial court filed an opinion in which it concluded that Snyder’s petition, although titled petition for habeas corpus, contained no averments of an improper or unlawful sentence. The court cited Weaver v. Pennsylvania Board of Probation and Parole, 688 A.2d 766 (Pa.Cmwlth.1997), for the proposition that habeas corpus is not available to challenge the constitutionality of the Board’s procedures and the factors considered in denying parole.
On appeal, Snyder argues that the trial court erred when it determined that it lacked jurisdiction; he also argues the merits of the claims in his petition for habeas corpus.
First we examine whether jurisdiction over the present appeal lies in Commonwealth Court or Superior Court. Superior Court has exclusive appellate jurisdiction over all appeals from orders of the courts of common pleas except those cases that are within the exclusive jurisdiction of the Supreme Court1 or Commonwealth Court. 42 Pa.C.S. § 742. *785If the present appeal does not fall within the exclusive appellate jurisdiction of Commonwealth Court, the appeal is within the appellate jurisdiction of Superior Court.
Because the present matter does not involve a regulatory criminal case, a government agency appeal under 42 Pa.C.S. § 983, a local government or private corporation matter, eminent domain, or an immunity waiver matter, Commonwealth Court would have exclusive appellate jurisdiction over the present appeal only if it were a Commonwealth civil case, which 42 Pa.C.S. § 762(a)(l)(i) describes as all civil actions, the original jurisdiction of which is vested in another tribunal by virtue of the exceptions to 42 Pa.C.S. § 761(a)(1) relating to our original jurisdiction, except proceedings in the nature of habeas corpus or post-conviction relief not ancillary to proceedings within our appellate jurisdiction. Reading these sections together, it is clear that the present appeal does not fall within our exclusive appellate jurisdiction. 42 Pa. C.S. § 762(a)(l)(i). Because no party has objected to our jurisdiction over this appeal, and in the interest of judicial economy, we will address the merits of the appeal. See Estate of Kinert v. Department of Revenue, 693 A.2d 643, 645 n. 1 (Pa.Cmwlth.1997).
In support of his argument that jurisdiction over his petition lies in the trial court, Snyder acknowledges that jurisdiction over parole matters generally lies in the Commonwealth Court, but that jurisdiction over a petition for habeas corpus lies in the courts of common pleas. He cites Justice Castille’s concurring opinion in Coady v. Vaughn, 564 Pa. 604, 610-11, 770 A.2d 287, 291 (2001), in which he opined that Pennsylvania law does not foreclose the possibility that constitutional claims in connection with a denial of parole may be brought as original actions in the courts of common pleas under the state habeas corpus statute. The Board counters that habeas corpus is not available to challenge the denial of parole, citing our decisions in Gillespie v. Department of Corrections, 106 Pa.Cmwlth. 500, 527 A.2d 1061 (1987), and Weaver.
On this matter, we agree with the Board. Gillespie and Weaver, and the cases cited therein,2 conclude that habeas corpus is not available to challenge the denial of parole because the inmate is serving a legal sentence and parole is a matter of discretion. A habeas corpus petition may be used only to challenge the legality of a sentence, that is, the state’s right to confine the inmate or the length of confinement, and not the denial of parole. Gillespie; Weaver. The trial court did not err when it concluded that it lacked jurisdiction to consider Snyder’s claims; however, having so concluded, the trial court should have transferred the petition to Commonwealth Court for consideration in our original jurisdiction pursuant to 42 Pa.C.S. § 5103(a), which mandates the transfer of a matter erroneously filed in the wrong court. Snyder’s petition, although erroneously titled as a petition for habeas corpus, named William Ward, Chairman of the Pennsylvania Board of Probation and Parole, as a respondent and therefore falls within our original jurisdiction as a civil action against the Commonwealth government. 42 Pa.C.S. § 761(a)(1).
In the interest of judicial economy,3 we affirm the order of the Court of Common Pleas of Blair County without prejudice to *786Snyder to file a petition for review in our original jurisdiction.
ORDER
AND NOW, this 5th day of August 2003, the order of the Court of Common Pleas of Blair County in the above-captioned matter is affirmed without prejudice to petitioner to file a petition for review in our original jurisdiction within 30 days of entry of this order.
. Clearly this appeal does is not within the appellate jurisdiction of the Supreme Court as it does not involve a general rule, right to public office, review of a death sentence, su-persession of a district attorney, indebtedness of the Commonwealth or a political subdivision, a matter repugnant to constitution, law, treaty or home rule charter, or the right to practice law. 42 Pa.C.S. § 722.
. Most notably, Commonwealth ex rel. Biglow v. Ashe, 348 Pa. 409, 35 A.2d 340 (1944).
. The alternative would be to remand to the court of common pleas and direct the transfer of the petition to this Court in our original jurisdiction.