Opinion by
Mr. Justice Stewart,
The appeal challenges the constitutionality of an act qf assembly which falls within a class of legislation distinguished from other legislation by its strictly humanitarian ends, and is directed especially to the betterment *533of conditions surrounding the youth of the State, having special reference to such of this class as are unfortunate enough to be lacking parental care or guardianship. The necessity for such legislation has come to be realized in recent years as never before. Witness our acts of assembly which forbid the employment of minors under a certain age in certain industries, requiring their attendance upon the public schools, the extended jurisdiction given the courts with respect to dependent and delinquent children and the beneficient provisions for their correction, education, moral instruction and training and general welfare. To these helpful and beneficial acts many might be added others which have been enacted in recent years, all showing an awakened public solicitude for and on behalf of the children of the State. We approach the consideration of the question before us, therefore, fully realizing that a decision adverse to the act will occasion deep regret, especially among those ivhose disinterested zeal on behalf of a dependent class has contributed largely to the passage of the act. This much we may be permitted to say, that, as citizens of the Commonwealth, they would have just cause for deeper regret should the court before which the question is brought for adjudication, disregard plain and positive constitutional requirements in order that an act of assembly, because of its beneficent aim, might be sustained.
The act in question was approved May 5, 1915, P. L. 244, and is entitled “An act requiring counties now or hereafter containing a population of not less than seven hundred and fifty thousand, and not more than one million two hundred thousand inhabitants, to establish and maintain schools for the care and education of female children under the jurisdiction of the juvenile courts, and conferring the power and regulating the proceedings for the establishment, maintenance and management thereof.” The title sufficiently discloses the purpose and scope of the act as to make it unnecessary for present *534purpose to recite here its several provisions; and further, it adequately presents the facts out of which arises one controlling question to which we shall confine the present discussion, namely, the legality of the classification of counties attempted in the act. The only legal method of classifying counties is by population: Com. ex rel. Fertig et al. v. Patton et al., 88 Pa. 258. Although the rule has in this case been observed, it by no means follows that this in itself warrants the classification made, for, back of the method to be observed, is the question of the right of the legislature to classify in the particular case. The limits within that right exists, in view of our frequent decisions on the subject, may now be regarded as clearly defined, as much so as the method by which it is to be accomplished. Except as a classification in any case upon Avhich legislation is based, is found to be a proper exercise of legislative power, it necessarily results that any legislation affecting the particular class thus created, and no other, is transgressiVe of the provisions of the Constitution which prohibits local and special legislation. Legislation becomes special when it can not under its terms operate generally. Classification is allowed because of necessity, a necessity defined in Ayars’ App., 122 Pa. 266, as “springing from manifest peculiarities clearly distinguishing those of one class from each of the other classes, and imperatively demanding legislation for such class separately that would be useless and detrimental to the other”; or, as in Commonwealth v. Gilligan, 195 Pa. 504, a necessity “springing from a great, or urgent public convenience.” It matters little which-of these definitions we adopt; tested by either, the classification here attempted must stand without legal excuse or justification. It is only necessary to refer to some of the more striking features of the classification adopted. Philadelphia County alone of all the counties of the State is excluded, for no apparent reason other than that her population exceeds the maximum fixed in the act, a county which might well *535be supposed to be in greatest sympathy with the beneficent aims of the act, and, because of its conditions, in at least equal need with any other county of the group of the benefits likely to be conferred. With Philadelphia County excluded there remains but a single county to Avhich the act could presently apply, the County of Allegheny. This county having a population according to the last decennial census of 1,018,4G3 would for an indefinite and uncertain period constitute the entire class, since the county next greatest in population would have to almost double its population of 343,000 before it could be admitted. Other counties in the State than Allegheny can be introduced only as they attain to the minimum population of 750,000. For this indefinite period which, except for some adventitious happening quite beyond legislative prevision, Avill extend far into the future, Allegheny County, should she so long remain in her present minority, must continue to be the only member of its class. Should she meanAvhile increase her population beyond the maximum limit she Avould automatically pass out of the class and leave it practically extinct, except as something unexpected should happen to prevent such result by suddenly doubling the population of the county next greatest in this particular. Now, however great may be the necessity for a school of this character in Allegheny County, or however urgent the convenience such school would there serve, such necessity or urgency can not be affirmed in any degree with respect to the other counties composing the class; nor indeed can any necessity or convenience be affirmed of them in this connection other than that they are needed to constitute a class one of which, the County of Allegheny, shall be a member, to the end that it may under guise of general law secure the benefit of legislation in its nature purely local and special and which can not apply to them for years to, come, if ever. It can not with any reáson be contended that the counties thus associated in the act as a class are marked by any common distinction or pe*536culiarity which, would make general legislation affecting-all the counties in the State burdensome, oppressive, or inconvenient as to them.
A feature of the act which goes far to support the contention that the only purpose of the act is to make it applicable to Allegheny County is found in the various, provisions which contemplate its immediate enforcement and provide the necessary machinery therefor, and the entire failure to provide any method for its enforcement in counties that might hereafter become ripe for admission into the class. To illustrate, — Section 5 of the act provides that each school created by the act shall be governed' by a board of managers; that each board shall be appointed by the judges of the court or Courts of Common Pleas of the particular county, to serve for unequal terms, and that the time of the commencement of the terms of said managers shall not be “later than July 1, 1915.” No provision whatever is made for the appointment of a board of managers in any county which may later be brought into the class. Again, Section 7 provides that the county commissioners may upon the request of the board of managers, prior to the year 1916, issue bonds for the establishment of such schools, or appropriate to the same to the maintenance thereof, out of the county treasury of such sum or sums as they may find it convenient to expend. Certainly the provisions of the act abundantly admit of its immediate application to the County of Allegheny, and it is equally clear that to make it operate in the other counties as they acquire the minimum population and so become qualified for entrance into the class, further legislation will be required as to them.
Several other reasons are advanced why the act should be held unconstitutional. We are so well convinced that it offends in the way we have indicated that nothing is to be gained by pursuing the matter further. For the reasons stated we think that the conclusion is unavoidable that the classification attempted by the act is *537one both arbitrary and artificial, resting on no sufficient basis, and as a necessary result what pretends to be.a general law is purely a local and special enactment falling within constitutional prohibition. Such legislation has frequently been characterized by this court as both specious and vicious. The question in the case was raised by demurrer to the answer filed to a petition asking that a writ of mandamus issue directed to the commissioners of Allegheny County requiring them to make provisions for the establishment, equipment and maintenance of such school as the act contemplates. The answer set up the unconstitutionality of the act. ' The court sustained the demurrer and entered judgment directing that a writ of peremptory mandamus issue. Thereupon the Commonwealth took the present appeal.
For the reasons stated in this opinion, the judgment is reversed.