The Federal eight-hour day law began to receive attention from the Federation towards the end of the eighties. By that time the status of the law of 1868 which decreed the eight-hour day on Federal government work[71] had been greatly altered. In a decision rendered in 1887 the Supreme Court held that the eight-hour day law of 1868 was merely directory to the officials of the Federal government, but did not invalidate contracts made by them not containing an eight-hour clause. To counteract this decision a special law was passed in 1888, with the support of the Federation, establishing the eight-hour day in the United States Printing Office and for letter carriers. In 1892 a new general eight-hour law was passed, which provided that eight-hours should be the length of the working day on all public works of the United States, whether directed by the government or under contract or sub-contract. Within the next few years interpretations rendered by attorney generals of the United States practically rendered the law useless.

In 1895 the Federation began to press in earnest for a satisfactory eight-hour law. In 1896 its eight-hour bill passed the House of Representatives unanimously. In the Senate it was introduced by Senator Kyle, the chairman of the committee on Education and Labor. After its introduction, however, hearings upon the bill were delayed so long that action was prevented during the long session. In the short session of 1898-1899 the bill met the cruel fate of having its introducer, Senator Kyle, submit a minority report against it. Under the circumstances no vote upon the bill could be had in the Senate. In the next Congress, 1899-1901, the eight-hour bill once more passed the House of Representatives only to be lost in the Senate by failure to come to a vote. In 1902, the bill again unanimously passed the House, but was not even reported upon by the Senate committee. In the hearings upon the eight-hour bill in that year the opposition of the National Manufacturers' Association was first manifested. In 1904 the House Labor Committee sidetracked a similar bill by recommending that the Department of Commerce and Labor should investigate its merits. Secretary Metcalf, however, declared that the questions submitted to his Department with reference to the eight-hour bill were "well-nigh unintelligible." In 1906 the House Labor Committee, at a very late stage in the session, reported "favorably" upon the eight-hour bill. At the same time it eliminated all chances of passage of the bill through the failure of a majority of the members of the committee to sign the "favorable" report made. This session of Congress, also, allowed a "rider" to be added to the Panama Canal bill, exempting the canal construction from the provisions of the eight-hour law. In the next two Congresses no report could be obtained from the labor committees of either House upon the general eight-hour day bill, despite the fact that President Roosevelt and later President Taft recommended such legislation. In the sessions of the Congress of 1911-1913 the American Federation of Labor hit upon a new plan. This was the attachment of "riders" to departmental appropriation bills requiring that all work contracted for by these departments must be done under the eight-hour system. The most important "rider" of this character was that attached to the naval appropriation bill. Under its provisions the Attorney-General held that in all work done in shipyards upon vessels built for the Federal government the eight-hour rule must be applied. Finally, in June 1912, a Democratic House and a Republican Senate passed the eight-hour bill supported by the American Federation of Labor with some amendments, which the Federation did not find seriously objectionable; and President Taft signed it.

Still better proof of the slight influence of the Federation upon government is furnished by the vicissitudes of its anti-injunction bills in Congress. The Federation had been awakened to the seriousness of the matter of the injunction by the Debs case. A bill of its sponsoring providing for jury trials in "indirect" contempt cases passed the Senate in 1896 only to be killed in the House. In 1900 only eight votes were recorded in the House against a bill exempting labor unions from the Sherman Anti-Trust Act; it failed, however, of passage in the Senate. In 1902 an anti-injunction bill championed by the American Federation of Labor passed the House of Representatives. That was the last time, however, for many years to come when such a bill was even reported out of committee. Thereafter, for a decade, the controlling powers in Congress had their faces set against removal by law of the judicial interference in labor's use of its economic strength against employers.

In the meantime, however, new court decisions made the situation more and more critical. A climax was reached in 1908-1909. In February 1908, came the Supreme Court decision in the Danbury Hatters' case, which held that members of a labor union could be held financially responsible to the full amount of their individual property under the Sherman Anti-Trust Act for losses to business occasioned by an interstate boycott.[72] By way of contrast, the Supreme Court within the same week held unconstitutional the portion of the Erdman Act which prohibited discrimination by railways against workmen on account of their membership in a union.[73] One year later, in the Buck's Stove and Range Company boycott case, Gompers, Mitchell, and Morrison, the three most prominent officials of the American Federation of Labor, were sentenced by a lower court in the District of Columbia to long terms in prison for violating an injunction which prohibited all mention of the fact that the plaintiff firm had ever been boycotted.[74] Even though neither these nor subsequent court decisions had the paralyzing effect upon American trade unionism which its enemies hoped for and its friends feared, the situation called for a change in tactics. It thus came about that the Federation, which, as was seen, by the very principles of its program wished to let government alone,—as it indeed expected little good of government,—was obliged to enter into competition with the employers for controlling government; this was because one branch of the government, namely the judicial one, would not let it alone.

A growing impatience with Congress was manifested in resolutions adopted by successive conventions. In 1902 the convention authorized the Executive Council to take "such further steps as will secure the nomination—and the election—of only such men as are fully and satisfactorily pledged to the support of the bills" championed by the Federation. Accordingly, the Executive Council prepared a series of questions to be submitted to all candidates for Congress in 1904 by the local unions of each district.

The Federation was more active in the Congressional election of 1906. Early in the year the Executive Council urged affiliated unions to use their influence to prevent the nomination in party primaries or conventions of candidates for Congress who refused to endorse labor's demands, and where both parties nominated refractory candidates to run independent labor candidates. The labor campaign was placed in the hands of a Labor Representation Committee, which made use of press publicity and other standard means. Trade union speakers were sent into the districts of the most conspicuous enemies of labor's demands to urge their defeat. The battle royal was waged against Congressman Littlefield of Maine. A dozen union officials, headed by President Gompers, invaded his district to tell the electorate of his insults to organized labor. However, he was reelected, although with a reduced plurality over the preceding election. The only positive success was the election of McDermott of the commercial telegraphers' union in Chicago. President Gompers, however, insisted that the cutting down of the majorities of the conspicuous enemies of labor's demands gave "more than a hint" of what organized labor "can and may do when thoroughly prepared to exercise its political strength." Nevertheless the next Congress was even more hostile than the preceding one. The convention of the Federation following the election approved the new tactics, but was careful at the same time to declare that the Federation was neither allied with any political party nor had any intention of forming an independent labor party.

In the Presidential election of 1908, however, the Federation virtually entered into an alliance with the Democrats. At a "Protest Conference" in March, 1908, attended by the executive officers of most of the affiliated national unions as well as by the representatives of several farmers' organizations, the threat was uttered that organized labor would make a determined effort in the coming campaign to defeat its enemies, whether "candidates for President, for Congress, or other offices." The next step was the presentation of the demands of the Federation to the platform committees of the conventions of both parties. The wording of the proposed anti-injunction plank suggests that it had been framed after consultation with the Democratic leaders, since it omitted to demand the sweeping away of the doctrine of malicious conspiracy or the prohibition of the issuance of injunctions to protect business rights, which had regularly been asked by the American Federation of Labor since 1904. In its place was substituted an indefinite statement against the issuance of injunctions in labor disputes where none would be allowed if no labor dispute existed and a declaration in favor of jury trial on the charge of contempt of court.

The Republicans paid scant attention to the planks of the Federation. Their platform merely reiterated the recognized law upon the allowance of equity relief; and as if to leave no further doubt in the minds of the labor leaders, proceeded to nominate for President, William H. Taft, who as a Federal judge in the early nineties was responsible for some of the most sweeping injunctions ever issued in labor disputes. A year earlier Gompers had characterized Taft as "the injunction standard-bearer" and as an impossible candidate. The Democratic platform, on the other hand, verbatim repeated the Federation plank on the injunction question and nominated Bryan.

After the party conventions had adjourned the American Federationist entered on a vigorous attack upon the Republican platform and candidate. President Gompers recognized that this was equivalent to an endorsement of Bryan, but pleaded that "in performing a solemn duty at this time in support of a political party, labor does not become partisan to a political party, but partisan to a principle." Substantially, all prominent non-Socialist trade-union officials followed Gompers' lead. That the trade unionists did not vote solidly for Bryan, however, is apparent from the distribution of the vote. On the other hand, it is true that the Socialist vote in 1908 in almost all trade-union centers was not materially above that of 1904, which would seem to warrant the conclusion that Gompers may have "delivered to Bryan" not a few labor votes which would otherwise have gone to Debs.

In the Congressional election of 1910 the Federation repeated the policy of "reward your friends, and punish your enemies." However, it avoided more successfully the appearance of partisanship. Many progressive Republicans received as strong support as did Democratic candidates. Nevertheless the Democratic majority in the new House meant that the Federation was at last "on the inside" of one branch of the government. In addition, fifteen men holding cards of membership in unions, were elected to Congress, which was the largest number on record. Furthermore William B. Wilson, Ex-Secretary of the United Mine Workers, was appointed chairman of the important House Committee on Labor.