Goals in each half from their Belgium striker Kevin Mirallas ensured Moyes departed from the blue half of Merseyside a winner after 11 years in charge of the Toffees.
Moyes, 50, is joining Everton's rivals Manchester United as the replacement for fellow Glaswegian Alex Ferguson, who is stepping down after 26 years in charge at Old Trafford.
It was not clear how Everton fans would feel about their manager leaving for United but he was warmly received by the crowd, who showed their appreciation for the progress the club has made under him despite the failure to win a trophy.
Their reaction was also helped by the fact they will finish above great rivals Liverpool for the second consecutive season.
"There's always a worry when you're joining another club, but Everton fans were magnificent for me today," Moyes told the BBC.
"David Unsworth scored my first goal at Goodison 11 years ago after about 25 seconds and I'm delighted I finished it off here with a win. I thank all the players who have worked with me."
After 71-year-old Ferguson announced his retirement on Wednesday the Manchester club took barely a day to appoint Moyes as his successor.
Everton, on the other hand, were surprised by the speed of developments, despite Moyes' contract running out at the end of the season, and a replacement has yet to be named.
Moyes was confident that whoever took over from him would make the most of a small but talented squad.
"Whoever comes in is going to have joy working with the current set of players," he said before contemplating his last game in charge of Everton next Sunday.
"I've got another week and I'm going to make sure I'm at it with the players because we want a result at Chelsea.
"The victory (over West Ham) was deserved. We're going to finish in a good league position and I'm happy with that," he added with Everton certain to end the season in sixth place.
Ferguson had recommended Moyes as his replacement, and the younger Scot said he would have no qualms about suggesting who should take over from him at Goodison Park if asked.
"I haven't recommended anyone for the job to the chairman (Bill Kenwright). If he asks me for an opinion then I'll give it to him," he added.
Ferguson's own farewell on Sunday also ended on a high as United beat Swansea City 2-1 at Old Trafford and were presented with the Premier League trophy, the 13th of his reign.