Mayfield tested positive for a banned substance last weekend at Richmond International Raceway. NASCAR spokesman Jim Hunter would not reveal what banned substance Mayfield used, but Hunter said it was not an alcohol-related offense.
"There is no place for substance abuse in our sport," Hunter said.
NASCAR also suspended two crew members for failed tests at Richmond.
Tony Martin, a crew member for the car John Andretti drove last weekend at Richmond, and Ben Williams, a crew member for the Nationwide Series car Matt Kenseth drove last weekend, were both suspended indefinitely.
Mayfield, who is driving a car this season he owns himself, failed to qualify for Saturday night's Sprint Cup race at Darlington Speedway.
He did not immediately return a voicemail message left on his cell phone Saturday by The Associated Press.
The suspension applies to Mayfield's roles as owner and driver of the No. 41 Toyota. Although the car can race next week at Lowe's Motor Speedway with another driver, Hunter said it cannot be entered with Mayfield as the owner.
Just days after the Daytona 500, one of Mayfield's crew members became the first person punished under NASCAR's new drug policy for a failed test. Mayfield fired Paul Chodora after he was suspended by NASCAR.
"We as an organization appreciate NASCAR's drug testing policies and policing efforts as it makes the sport stronger overall," Mayfield said after firing Chodora. "If Paul doesn't comply with NASCAR's reinstatement process, then he will no longer be an employee of Mayfield Motorsports."
Mayfield, a two-time qualifier for the Chase for the championship, has five Cup victories in 433 career starts, but none since 2005 at Michigan. He was fired by Evernham Motorsports in late 2006 and bounced around until this season, when he formed Mayfield Motorsports.
He threw the team together in less than a month but made headlines as the underdog who raced his way into the season-opening Daytona 500. But he made just four of the next 10 races, and is currently 44th in the Cup standings.
NASCAR announced a new, tougher drug policy last September. The guidelines were strengthened in part because of former Truck Series driver Aaron Fike's admission that he had used heroin even on days he raced. That led Tony Stewart, Kevin Harvick and other veteran drivers to call on NASCAR to add random drug testing to its policy.
Under the new rules, all drivers and crew members had to be tested before the season began. Random tests are scheduled throughout the year, and at least four drivers are tested each weekend. Hunter said the drivers are selected through an automated computer program.
Trucks driver Ron Hornaday last year admitted using testosterone for more than a year before it was added to the sport's banned list to treat a medical issue. Hornaday has Grave's disease, a condition he is now treating with Synthroid, which replaces a hormone normally produced by the thyroid gland to regulate the body's energy and metabolism.
NASCAR did not punish him for the testosterone admission because the cream did not enhance his performance or impair his judgment.
NASCAR's past policy allowed for testing any time series officials had "reasonable suspicion" to question a driver or crew member. Fike's admission forced NASCAR to begin a weekly, random process.
On Wednesday, former Nationwide Series driver Kevin Grubb was found dead in a Richmond-area motel room from what police said was an apparent self-inflicted gunshot wound to the head. Grubb was suspended indefinitely by NASCAR after a second failed drug test in 2006 and never raced again in a NASCAR sanctioned event.
Shane Hmiel, who made 119 starts in NASCAR's top three national series, received a lifetime suspension in 2006 after a third failed drug test. Hmiel, who made seven Cup starts in 2004 and 2005, won the Truck Series race at Las Vegas in 2004.