Boufal came off the bench in the 81st minute and broke the deadlock with a stunning solo goal which began inside his own half, securing the hosts a much-needed second home win of the season.
Despite the Saints' struggles, the former club-record signing has only started one of nine league matches and marked his winner with a potentially antagonistic celebration in front of Pellegrino.
The 24-year-old admitted after the match it was "most important" to prove himself to the Southampton boss, who has no doubt about his quality.
"Sofiane has got the ability to do it," Pellegrino told the BBC's Match of the Day.
"We had to make changes at the end because [West Brom switched to] five defenders. We made the right decision and got the victory for more confidence for the next game.
"I can say that we have got a group of players and most of them deserve to play, but the manager has to choose the XI. Sofiane has to wait for his opportunity."
Boufal's winner consigned West Brom to a third league defeat and seventh in succession without victory.
Baggies boss Tony Pulis believes his team should not have allowed the 85th-minute strike to transpire.
"The viewers will see it and think it's a wonderful goal," he said. "[Boufal went] past five players. One or two you would hope would do better. It's disappointing.
"We really had the best opportunity of the game [in Jay Rodriguez's one-on-one]. If we score there it's a different game."