All the goals came during the second half with captain Badr Benoun temporarily abandoning his centre-back duties to trigger the rout with a 52nd-minute goal at the Stade Mohamed V.
Mahmoud Benhalib, leading scorer in the second-tier African club competition last season with 12 goals, netted soon after and Abderrahim Achchakir converted a penalty on 68 minutes.
With the two-leg tie slipping from their grasp, the Gabonese collapsed in the closing stages and Ben Soumahoro conceded an own-goal before Ugandan Muhammad Shaban completed the rout.
The clubs meet again this Saturday in Libreville and the only issue to be resolved would appear to be how many goals Raja will win by on aggregate.
Raja were the second biggest round-of-32 first leg winners after Zamalek of Egypt, who humiliated ASCOT of Chad 7-0 in Cairo Saturday.
Record three-time Confederation Cup winners CS Sfaxien, fellow Tunisians Etoile Sahel, Kaizer Chiefs of South Africa, Renaissance Berkane of Morocco and KCCA of Uganda built three-goal leads.
The African equivalent of the UEFA Europa League has been dominated by clubs from the north of the continent, who have won 10 of the 15 finals.