Dimitri Petratos had opened the scoring in the 16th minute with a penalty from a hand ball by Andreu Gueroa.
Four minutes later Brisbane went ahead 2-0 when a shot by Corona deflected off Andreu and only three more minutes passed before Maclaren scored to make it 3-0.
Western Sydney's comeback began with Castelen's first goal in the 26th minute and a 39th-minute goal to Brendon Santalab sent them to halftime only a goal behind.
Castelen equalized in the 53rd minute, then gave Wanderers the lead six minutes later with a goal that seemed likely to break Brisbane's spirit.
But Brisbane had already staged a remarkable comeback to reach the semifinal, scoring twice in the last four minutes to beat defending champion the Melbourne Victory 2-1 in last weekend's playoff.
They rallied again Sunday, snatching an 80th-minute equalizer to force the match to extra time.
Vidosic struck the winning goal in the 102nd minute and Western Sydney was able to hold on in the fatiguing second half of extra time to clinch the win.
They now face Adelaide, which beat Melbourne City 4-1 in Friday's first semifinal, and will likely enter their first A-League grand final as favorites.
Western Sydney will be appearing in a grand final for the third time, having twice finished runner-up.
-AAP