Johnny Hunt scored Wrexham's winning penalty after Sam Hatton and Richard Brodie missed kicks for Grimsby.
Andy Cook had given Grimsby the lead, firing home after his first shot had been blocked by Chris Maxwell.
But Kevin Thornton levelled from the spot after Dean Keates had been fouled to set up extra-time, which produced no further goals as the game ended 1-1.
Wrexham fully deserved their victory after dominating against their Blue Square Bet Premier promotion rivals in front of a crowd of more than 35,000 fans.
Defenders Aswad Thomas and Shaun Pearson both shrugged off injuries to take their places in the Grimsby line-up, while for Wrexham, captain Dean Keates returned from suspension to replace Joe Clarke and player-manager Andy Morrell started in place of Dele Adebola.
The Mariners had the first meaningful attack with Johnny Hunt having to head away Marcus Marshall's teasing cross for a corner from which Frankie Artus' long-range effort cleared the crossbar.
The game sprang into life when a two-footed challenge by Grimsby's Craig Disley on Keates provoked a reaction from the Wrexham players, but referee Jon Moss took no action against Disley, deeming a Wrexham free-kick to be sufficient.
The Welsh side then enjoyed a good spell, with Jay Harris capitalising on a poor ball by Ian Miller and avoiding three challenges before firing over the bar from the edge of the penalty area.
Marshall, who was proving to be a real threat for Grimsby, had a chance with a header and Harris scuffed a shot wide after receiving the ball from Thornton.
Grimsby did venture forward in response, but more often than not their forays into the penalty area were quickly halted by Wrexham's defenders and a disappointing first half ended goalless.
Goalkeeper James McKeown was almost punished for a slip soon after the restart but recovered well to deny Morrell, but Wrexham should have gone in front two minutes later when Danny Wright missed a gilt-edged opportunity from six yards following Stephen Wright's corner.
Cook curled a shot wide for Grimsby, although the assistant referee had already flagged for offside, and Wrexham's Brett Ormerod, a Wembley winner with Blackpool in 2010, then headed over the crossbar from Hunt's cross.
Wrexham looked the more likely to break the deadlock, but it was Grimsby who did so on 70 minutes when Joe Colbeck's pull-back set up Cook, who although denied initially by Maxwell, smashed home the rebound from close range.
Man of the match Westwood and substitute Adrian Cieslewicz, who replaced Morrell, went close before Wrexham were awarded a penalty after Keates was tripped by Shaun Pearson in the area.
Thornton stepped up to take the kick and sent McKeown the wrong way to level the scores with nine minutes of normal time remaining.
The equaliser gave Wrexham renewed confidence and McKeown palmed away a Harris free-kick, which proved to be the final chance of note during the 90 minutes.
Cieslewicz was twice denied by McKeown during the first period of extra-time as Wrexham went in search of a winner.
They had the momentum going into the final 15 minute although Colbeck flashed a low effort wide from long range before the dangerous Cieslewicz was again denied by a fine save from the excellent McKeown, who followed that by touching a Danny Wright volley onto the post.
The teams could not be separated at the end of 120 minutes and penalties were needed for only the second time in history of FA Trophy finals.
Cieslewicz, Danny Wright, Westwood all found the net for Wrexham, but Hatton hit the post with Grimsby's first effort and Brodie blazed over.
Joe Colbeck kept his head to open Grimsby's account but it was too little, too late as the responsibility for Wrexham's fourth penalty fell to 22-year-old Hunt and he converted confidently to secure the trophy  for the north Wales club.
Grimsby Town joint boss Rob Scott told BBC Radio Humberside:
Media playback is not supported on this device
"That was a big disappointment for everybody. I think once you get into the territory of penalties, then it is a lottery.
"I'm sure people will be sat there saying 'why did you let him take that penalty', but you can't replicate what we had today.
"It's not the case that we haven't practised penalties; we knew who our penalty takers would be before it got to that stage.
"I can't lay the blame at anyone's door for missing a penalty, it's just one of those things."
Grimsby: McKeown, Hatton, Thomas, Pearson, Miller, Colbeck, Disley, Artus, Cook, Hannah (Thanoj 55), Marshall (Brodie 87).
Subs Not Used: Devitt, Wood, John-Lewis.
Wrexham: Maxwell, Stephen Wright, Riley, Harris, Danny Wright, Ormerod (Ogleby 77), Morrell (Cieslewicz 60), Keates, Hunt, Westwood, Thornton.
Subs Not Used: Coughlin, Clarke, Little.
Att: 35,266
Ref: Jon Moss (W Yorkshire).
Wrexham became the first Welsh club to lift the FA Trophy after a 4-1 penalty shootout win over Grimsby at Wembley.