The Premier League club were informed of the positive tests while preparing for Tuesday’s Carabao Cup tie against Hull City at London Stadium.
Moyes, 57, defender Issa Diop, 23, and 24-year-old midfielder Josh Cullen will now be required to self-isolate.
“The manager and both players immediately left the stadium and have returned home,” said a club statement.
West Ham said the three men were all asymptomatic and assistant manager Alan Irvine took charge of the Hull match, which both Diop and Cullen were due to start.
Public Health England guidelines state those with Covid-19 should self-isolate for at least 10 days, meaning Moyes, Diop and Cullen will not be able to attend training or the league game against Wolverhampton Wanderers on 27 September.
BBC Radio 5 Live’s John Southall said the trio travelled to the ground with the squad in two or three separate coaches.
“They say they all social distanced, the squad, from when they met up and throughout the journey,” he said.
“As soon as they arrived, the results from the tests done yesterday came through and the two players and the manager were isolated immediately in separate rooms and left the ground very quickly, I’m told.
“West Ham say they are satisfied nobody else in the squad needs to self-isolate and that is why the game went ahead.”
The news comes after Leyton Orient v Tottenham Hotspur in the EFL Cup third round on Tuesday was called off because a number of the home players had contracted coronavirus.
It came on the day the government announced a raft of new coronavirus restrictions for England which could last for up to six months.
As part of the stricter rules, Prime Minister Boris Johnson has confirmed plans for fans to return to watch live sport events in England from 1 October will not go ahead.
Sports bodies have been told not to expect spectators at stadiums and venues until the end of March at the earliest.