Though major league players were not tested for anabolic steroids until 2003, the use of steroids for performance enhancement has been implicitly banned by baseball since 1971 and expressly banned since '91.
Baseball's first written drug policy was issued by commissioner Bowie Kuhn at the start of the '71 season. The policy did not explicitly address anabolic steroids, but it did say that baseball personnel must "comply with federal and state drug laws." Federal law at the time mandated that an appropriate prescription be obtained for the use of anabolic steroids.
What followed were memos from commissioners Fay Vincent in 1991 and Bud Selig in '97 (excerpted below) that spelled out a broader drug policy and directly prohibited the use of steroids without a valid prescription. However, there was still no mandatory drug testing, and the union maintained the right to challenge disciplinary decisions that resulted from a violation of the policy.
A mandatory drug-testing policy was collectively bargained with the players' union in 2002, and the first survey testing was done the following year—when the 104 positive tests turned up.
A brief history of major league baseball's drug policy:
COMMISSIONER FAY VINCENT'S JUNE 7, 1991, MEMO
Each team and the players' union received the memo, which begins, "This memorandum sets forth Baseball's drug policy." The memo goes on to say, "The possession, sale or use of any illegal drug or controlled substance by Major League players or personnel is strictly prohibited.... This prohibition applies to all illegal drugs ... including steroids or prescription drugs for which the individual in possession of the drug does not have a prescription."
COMMISSIONER BUD SELIG'S MAY 15, 1997, MEMO
Selig reissued Vincent's statement on baseball's drug policy and also reiterated Vincent's assertion that any players violating the policy "risk permanent expulsion from the game," in addition to any penalty imposed by the player's club.
THE MITCHELL REPORT, RELEASED DEC. 13, 2007, CLARIFYING MLB'S DRUG POLICY