Eliezer Mayenda opened the scoring for the Black Cats in the 61st minute with a header.
Dan Ballard doubled Sunderland's lead in the 73rd minute, nodding home a header into the bottom corner.
Substitute Wilson Isidor secured the comprehensive win with a goal in added time, making it 3-0.
Sunderland, featuring seven new signings in their starting line-up, withstood early pressure from West Ham captain Jarrod Bowen before asserting their dominance.