The Scottish SPCA was called when the exhausted bird was spotted at Traprain Terrace in Haddington on 2 February.
Staff traced it back to its owner and the racing pigeon has now been returned to the royal loft at Sandringham estate in Norfolk.
The bird was identified by a ring number on its leg.
Connie O'Neill, Scottish SPCA animal rescue officer , said: "I've rescued many pigeons during my career with the Scottish SPCA but this was certainly a first for me.
"I was really excited when I found out it was one of the Queen's racing pigeons.
"We were able to identity where the pigeon had come from using the ring number on its leg and arrangements were made for it to be collected.
"The poor bird was exhausted and it was a cold, dark and windy night when it was found. Thankfully someone contacted us as it would have been very easy prey for a cat.
"It's quite common for racing pigeons to lose their way and become too tired to take off again. I'm really glad we were able to help in this instance."
Animal welfare officers who rescued a lost pigeon in East Lothian were surprised to discover it was owned by the Queen.