The policy change had been considered for months and is now effect, company spokesman Tom Williams said.
"Our continued growth requires us to be one of the more desirable employers around, so we're clearly stating our acceptance for all of our associates," Williams said. "Otherwise, we could lose many talented employees, and we don't want that."
Williams said company officials listened to employees and groups advocating the inclusion of gays and lesbians in antidiscrimination policies. The policy change "unfolded by itself," and last week's U.S. Supreme Court decision striking down anti-sodomy laws was not a factor in the decision, he said.
"We want all of our associates to feel treated with respect and valued, with no exceptions at all," Williams said.
David Smith, of the gay and lesbian group Human Rights Campaign, welcomed the news but said Wal-Mart should do more.
"It's very gratifying to see corporate America taking the lead on this," Smith told CBS News. "Wal-Mart should take the next step and provide domestic partner benefits, because ... the next step for them would be to offer health benefits to their gay employees."
The change means nine of the 10 largest Fortune 500 companies now have rules prohibiting discrimination against gay employees, according to the Human Rights Campaign. The one exception is the Exxon Mobil Corporation.
Wal-Mart Stores, based in Bentonville, Ark., is the world's largest retailer, with over 1.1 million employees worldwide.