The draw was enough for Queens as relegation rivals Stanraer lost to St Mirren and they will go into a play-off.
Queens attacked from the start and went close in two minutes when Paul Burns forced a save from goalkeeper Craig Nelson.
Brechin hit back and David Hannah laid the ball off for Stuart Callaghan to shoot wide then a Hannah drive from 30 yards was saved by Ritchie Barnard.
Back came Queens and in 20 minutes Sean O'Connor shot just wide from a Graham Weir pass.
Queens scored a vital goal in 22 minutes when O'Connor rose high to power home a header from a Ryan McStay free-kick.
Brechin hit back immediately and Graham Gibson was unlucky to head wide and then in 29 minutes Hannah headed over from a Callaghan free-kick.
In 40 minutes Queens went close again when John O'Neill drove over from a good position. Two minutes later a run from Burns ended with the ball going to O'Neill and his shot was saved by Nelson.
In 57 minutes O'Neill headed wide from a McStay corner but Brechin refused to give up and in 68 minutes Chris Geddes headed wide from a Callaghan corner.
Brechin were out of luck in 76 minutes when a Chris Templeman header from a Callaghan free-kick was cleared off the line by Stuart Lovell.
Brechin got a deserved equaliser in 79 minutes when Barnard was penalised for carrying the ball outside his box and Callaghan stepped up to drive home the free-kick.
Brechin battled to the end and in 89 minutes Geddes drove into the side-netting after a neat move then in stoppage time Geddes shot over from a good position.
DUKE'S REPORT -Queens battled hard for this draw as both teams struggled to play football on a most horrible bumpy pitch along with a swirling wind. Queens really should have secured both points but Barnard's fateful error let City in for their equaliser. No one was complaining however as Queens survive another record breaking season in Division 1.
DUKE'S MAN OF THE MATCH - The award goes to the fans as they were absolutely magnificent in fancy dress and sang their hearts out. I estimate around 400 Queens fans were present and I doubt if Brechin have ever seen anything like it before.