They are joined there by David Drysdale, who shot a best-of-the-day 67 and Craig Lee, who maintained his position as leading Scot with a third round of two-under-par 70 that left him in sixth place on eight-under 208, seven behind German leader Marcel Siem (69).
Ramsay, Gallacher and Scott Jamieson went into the tournament at the Golf du Palais Royal in Agadir needing to win to earn the place in the world's top 50 that would result in automatic qualification for Augusta.
Jamieson missed the cut but Ramsay climbed into a share of 13th yesterday after a three-under-par 69 that put him on four under for the tournament. Drysdale jumped 28 places to a tie for 16th on three under. Gallacher is on the same mark after a 70.
Siem, who also needs victory to book a ticket to the Masters, stretched his lead by one shot to four with a 69. In a three-way tie for second are Spain's Pablo Larrazabal (also 69), David Horsey of England and Finn Mikko Ilonen (both 70).
Siem had to overcome a nervy start that saw him bogey the first. He steadied with five straight pars before the first birdie of his round at the seventh kept his lead intact. It had been cut to a single stroke by this point but back-to-back birdies at the ninth and 10th eased the pressure.
The 32-year-old picked up another shot at the 16th but gave it straight back with a bogey at the 17th. "Until the 15th I was really happy with the round," Siem said. "I had a tough start and all the guys just behind me seemed to start really well.
"I had to hole a few big putts just to stay ahead and then I managed to pull away a little bit. But then 15 and 17 were disappointing because you are really looking to pick up a couple of shots there and I managed to give one away.
"There was pressure there so it was great to make a few putts and pick up four in six holes. It is very nice to have the gap back for the start of the final round. I am pretty confident. I know the swing is there when I trust it and just let it go. That will be very important tomorrow."
Horsey approached the turn in 33 but a disappointing back nine followed.