Opinion,
Mr. Justice Green:
The plaintiff, Schroeder, was a sub-contractor under the principal contractor, Olmsted, for the execution of a part of the work of the construction of a house for the defendant Galland. In the contract between the owner and the principal contractor it was expressly stipulated that the building should be built, finished, and delivered over to the owner, “ free of all liens and encumbrances, or any claims whatever, that might arise under *283any action of the party of the second part, or his legal representatives, under this contract.” And, again, it is provided that the payments were to be made to the party of the second part, “ provided the wages of all artisans and laborers, and all those employed by or furnishing materials to the said party of the second part, on account of this contract, shall have been paid and satisfied; ” and, further, “ in case the party of the second part fails to pay and satisfy all and every legal claim and demand, as aforesaid, against the building, the said party of the first part may, if he deems proper so to do, retain from the moneys due, if any, to the party of the second part, enough to satisfy such claims and demands, and if there be not enough due or coming, then the said second party covenants and agrees to pay the same. Said second party also agrees to pay sub-contractors, and parties furnishing materials on account of this contract, pro rata, at each estimate.” The owner seems to have guarded himself, as well as it was possible to do, by these provisions, against liens, claims, demands, and liabilities of and to any and all other persons than the principal contractor. The stipulation against liens is undoubtedly obligatory upon the principal contractor, and so far as he is concerned no lien could be filed: Long v. Caffrey, 93 Pa. 526; Scheid v. Rapp, 121 Pa. 593.
The controlling question of this case is, can the sub-contractor file a lien for the work and materials done and furnished by him, notwithstanding the stipulations of the principal contract ? If he can, the owner, instead of paying $9,000 for the completed house, according to the contract, will be obliged to pay therefor nearly $11,000.
The plaintiff filed his lien as a sub-contractor under Olmsted, whom he described as contractor, and with whom he contracted. He says in his claim of lien: “ The name of the person with whom Conrad Schroeder contracted is mamed Charles Olmsted.” He also states that the name.of the owner is Anna M. Galland, the wife of B. Galland. He therefore knew that he was dealing and contracting, not with the owner, but with one who was a contractor for the construction of the building. The only connection between the owner and this sub-contractor was through and by means of the written contract between the owner and the principal contractor. He *284could not, in such circumstances, contract with this person without being charged with notice of the contract of the latter with the owner, and, by necessary consequence, with notice of all its terms and stipulations.
A sub-contractor for construction is certainly bound to know the kind of building that is to be erected, the materials of which it is to be built, the price to be paid for it, and the manner and times of payment. He cannot, under a contract for the erection of a building at a cost of $1,000, furnish work and materials to the amount of $5,000. He cannot furnish wood as material for the erection of a building to be built of marble or stone or bricks. Nor can he furnish unsuitable materials, even of a kind demanded by the contract, and entitle himself to a lien therefor.
In the case of Harlan v. Rand, 27 Pa. 511, we decided that to entitle a material-man, who deals with the contractor, to have his lien, he must furnish materials suitable for the building and apparently adapted to it. There the contractor made a contract with a sub-contractor to furnish a heater of a new construction to heat the building. The sub-contractor employed the plaintiff, who claimed a lien, to do the work. The contract with the sub-contractor stipulated that if the heater did not answer the purpose of heating the building, it was to be removed at his expense. The claimant, who did the work, filed a lien for it, and this court held he was bound by the provisions of the contract with his employer, the sub-contractor, though he was no party to it, and rejected his lien. Lowbie, J., in delivering the opinion, said: “There are several cases that show that the material-man cannot justly charge the building for all the materials that he may choose to furnish on its credit, without reference to the quantity or quality needed. He must, in his supplies, regard the size and apparent character of the building-, and his lien cannot go beyond what these show to be reasonable: Odd Fellows’ Hall v. Masser, 24 Pa. 510..... And no one would think of saying that a material-man shall have a lien for materials furnished for a particular purpose, and which are unfit for it..... If they are furnished on the order of the owner of the house, of course this rule does not apply, for a man may pledge his own property for any kind of materials. But it is involved in the very fact of furnishing *285them to a contractor of the building, on its credit, that he should know its character, and that they must, at least apparently, be adapted to it.” On another branch of the case the same judge said: “When the owner employs a house builder to erect a house for him, the parties are directly connected by contract, and the lien must be founded on it.” The same thought is expressed and enforced in the recent case of Brown v. Cowan, 110 Pa. 588. We there say: “It is the plain and obvious duty of one who deals with an alleged contractor to know the relation which he bears to the owner. Failing in this, he furnishes labor or materials at his peril.”
Of course, it cannot be questioned for a moment that a subcontractor who undertakes the construction, in whole or in part, of a building, under a contract with the principal contractor, is absolutely bound by all the plans and specifications expressed in the original contract of the owner with the builder. He must conform to the original contract in all matters, and in the minutest detail, precisely as the builder would be obliged to do. It is most obvious that he cannot depart in any respect, either from the designs, the dimensions, the materials, the plans, shapes, and sizes, that are expressed in the original contract; and the reason is most manifest. He is the representative of the builder. He undertakes to perform the contract of the latter with the owner, either in whole or in part, and of course he must conform to that contract in every particular. It would be of no use for him to say that he did not know the particulars of that contract; he is bound to know them: it is a legal necessity arising from the fact that he has undertaken to do the work which his principal has engaged to do. He certainly cannot furnish pine wood for interior woodwork, when the owner’s contract with the builder calls for walnut, or cherry, or ash. He cannot furnish stone when the contract requires marble, or bricks when stone is designated, or one kind of stone when another kind is expressed, or wood instead of bricks. He cannot furnish a building of two stories when three are demanded by the contract, or of six rooms when ten are required. These conclusions are readily appreciated, and will be at once conceded. But to go further and into greater detail it must be equally plain that one who, as a subcontractor, agrees with the principal contractor to furnish ma*286terials only, for the building, is just as precisely bound as his principal by the stipulations of the original contract. If that contract requires the mantels to be of marble, he must make them of marble, and he not only could not acquire a right to a lien if he made them of slate or of wood, but he would not be entitled to any payment whatever from the owner for his work. And vice versa, if they were required to be of wood, he could not make them of marble or of slate. And so, if a carpenter should take a sub-contract for the wood-work, he could not furnish hemlock flooring when the owner’s contract required pine or ash, or doors made of pine when doors of walnut were specified. And so of painters and glaziers and plasterers, who take sub-contracts for the execution of their several specialties; they are all bound by the owner’s contract with the builder precisely as the builder himself is bound. They cannot be permitted to be ignorant of his limitations, or to plead such ignorance as an excuse for insufficient performance. And the reason for it all is most manifest. They are bound to do just what tlieir principal was bound to do, because they assumed to perform his contract with the owner, to the extent of their undertaking, and, of course, they must perform according to his express limitations. In other words, they necessarily have notice of the terms and stipulations of his contract with the owner, and that means, not a part, but all of those terms and stipulations. Upon the plainest legal principles applicable in all other cases, they cannot have the benefits of the builder’s contract without accepting the conditions upon which those benefits are conferred. If they could, they would defeat the explicit contract of the owner upon a point without which, it may easily be, he would never have consented to it. If the law would tolerate this method of dealing with building contracts, it would only be necessary for the original contractor to sub-let his contract by portions, to different persons, and the prohibition against liens would be utterly destroyed, and a contract would be enforced against the owner to which he never consented.
There is no hardship to sub-contractors in enforcing a provision prohibiting liens, against them, because they are bound to know, by necessity, all the terms of the contract made by their principal in any event, and they therefore know of the prohibition. *287But the owner has no opportunity of protecting himself, because he cannot know to what persons the contract, or portions of it, may be sub-let. He has done all he could do by prohibiting liens, in plain terms, in his written contract; and of that prohibition all sub-contractors are bound to know, and may abstain from contracting on such terms if they choose. We know of no good reason for giving such an extraordinary privilege to sub-contractors, as the fight to repudiate one of the most important terms to which their contracts are subject, or of ,taking away from an owner the right to insist upon the performance of his contract according to'its literal terms. We take away houses and lands from their owners by means of some secret lien or trust of which they know nothing, by applying the doctrine of constructive notice; and it would be passing strange for us to hold that the right of a sub-contractor for part of a building is of so sacred a character that it shall not be bound by the express limitations of a written contract, under which and by force of which his own contract must be performed. His right of lien has no existence at common law or in equity. It is a creature of statute alone; but the statute confers upon him no special prerogative to transcend the most familiar principles of the law, and to claim privileges which are denied to all other citizens in the determination of their contract rights. Let it be granted that a contractor, as well as the owner, has power to bind the building by a lien for work and materials; we have never yet held that he may confer that right upon a mere sub-contractor under him when, by the terms of his own contract, he does not possess the right himself. The question is one of first impression. Heretofore it has never been before us. It is with us now, and we are at liberty to decide it in accordance with our views of right and - justice and with those principles of the interpretation and administration of contracts between citizens which we unfailingly apply in all other cases.
In an old case, decided many years ago by the district court of Allegheny county, Campbell v. Scaife, 1 Phila. 187, the same conclusion we have reached was expressed and applied. The decision is of no binding authority upon this court, but the'reasoning of the opinion is of such clearness and force that some of it may well be repeated here. The learned court says: *288“The owner contracts with the builder to erect a house on certain terms, and the builder makes a sub-contract with a material-man to supply the materials. The claim of relationship consists of but two links, the second of which hangs by the first, and will bear no greater weight. The sub-contractor comes in by reason of his direct contract relation to the builder, and the right of lien of the former for his claim is, pro tanto, substitutionary to that of the latter. As, against the owner the terms of the original contract, and as against the builder the terms of the sub-contract, limit and qualify the lien of the sub-contractor, So as to prevent his claim from abating the terms of either contract.....The allowance of any lien at all to a sub-contractor is a special privilege granted only in case of buildings; and it is not unreasonable to require him to look to the principal contract to ascertain whether it is such as to justify him in becoming a contractor under it. The argument that the law and the principal contract make the builder the agent of the owner proves nothing. Suppose the fact to be so, still his agency is only special, limited by the terms of the contract. He is to employ men to build the house in the manner and on the terms there indicated. For anything beyond that, he exceeds his authority and does not bind his principal.” In the case of Dickinson College v. Church, 1 W. & S. 462, Mr. Justice Rogers, in delivering the opinion of this court, said: “ It is a great mistake which cannot be too soon corrected, if any suppose that when a person undertakes to furnish lumber to a contractor on the credit of a building, that he is relieved from inquiring into the nature of the building he trusts, whether it is brick or frame, whether it is a one- or three-story house, or whether it is large or small ,• that, in short, he can furnish materials enough to complete a three-story house of the largest dimensions, when the materials are intended for a house of the most inferior description. The very fact that he credits the building, and does not depend altogether on the personal responsibility of the contractor, should, it would seem, immediately suggest the propriety of making the necessary inquiries as to the size, materials, and nature of the intended erection.” In the state of California it has been held by their court of last resort, in two cases, that the right of the subcontractor to a lien is controlled by the terms of the original *289contract, and he is presumed to have notice of the terms of that contract: Shaver v. Murdock, 36 Cal. 298; Henley v. Wadsworth, 38 Cal. 356. Entertaining these views, we sustain the third, fourth, fifth, and sixth assignments of error.
Judgment reversed.