Two early goals made this a tough game for James Scott's team, but a goal from Millie Daly gave them hope before Portugal scored again. However, Mackin proved to be the hero with a second-half brace.
This was the first of two International Friendly games that Ireland arranged to help them with their final preparations for their upcoming UEFA WU17 European Championship Qualifiers in October.
The home team took the lead on eight minutes when Rita Almeida's corner kick evaded everyone and curled into the back of the net. The Sporting Lisbon ace didn't intend for the ball to go that far but she was happy to take the goal.
Portugal increased their lead on 15 minutes after a clever pass through set Leonete Maísa away. The speedy striker took her time before firing an angled shot past goalkeeper Nicole Nix.
Ireland worked hard to find a way back into the game with Aoife Turner and Alice Lillie impressing in the full-back positions, while Daly was a threat on the left flank and set up a great opportunity for Joy Ralph but the DLR Waves forward failed to make a clean connection with the ball.
On 36 minutes, that persistence paid off with Daly's goal. The Athlone Town ace peeled off her marker to control a chipped pass from Ellen Dolan and then applied her own lobbed effort that goalkeeper Adelaide Paredes tried to parry out but was unable to as the ball hit the inside of the far post before crossing the line.
Unfortunately for Ireland, the hosts got a third goal before half-time when Aoibhe Fleming mishit an attempted clearance and Lara Martins pounced from close range to blast in.
Upon returning for the second half, there was more of a bite to Ireland's play and they were the team applying most of the pressure. Another goal felt like only a matter of time in being delivered.
It was Mackin who supplied that goal, on 72 minutes, when the Cork City defender blasted in a free-kick from around 30 yards out. It was the type of goal that deserves to be watched again...and again.
Mackin wasn't done though. She got her second of the day when Paredes flapped at a free-kick from Jess Fitzgerald and the ball landed just in front of Mackin to bundle it over the line and bring the scoreline level.
Ireland could have sealed the win late on when substitute Ruby Gallagher broke clear and took on a shot from distance but it fizzed wide of the goal.
These games will stand to Ireland going into their European Championship Qualifiers - against Austria, Finland and Northern Ireland - and Scott will be pleased by their attitude in earning a draw.
Portugal: Adelaide Paredes; Érica Cancelinha, Inês Meninas, Rita Cunha (Luana Rafael 83), Maria Chaves (Anna Luísa Marques 63); Marta Gago, Rita Almeida (Sorana Godzsa 63), Mafalda Mariano (Alice Reto 74), Nicole Cassamá (Neide Guedes 74); Leonete Maísa (Rita Melo 74), Lara Martins (Luisa Brás 63).
Republic of Ireland: Nicole Nix; Aoife Turner (Niamh Tyrrell 82), Aoibhe Fleming (Grace Fitzpatrick Ryan 82), Heidi Mackin, Alice Lillie (Kiera Sena 57); Ellen Dolan (Ruby Gallagher 71), Aoife Kelly (Jess Fitzgerald 57); Katie Lawlee (Fiana Bradley 57), Jodie Loughrey, Millie Daly (Hannah Healy 71); Joy Ralph (Freya Healy 82).
Referee: Sílvia Domingos (Portugal).
International Friendly Games
October 2nd | Portugal v Republic of Ireland, Cidade do Futebol, KO 17:00