The undated image is thought to have been taken in 1999, when Prince Andrew reportedly invited the couple to stay at the Scottish estate.
Ms Maxwell, 59, is currently on trial for allegedly grooming teenage girls for abuse by the late Epstein between 1994 and 2004.
She has denied all the charges.
Defence lawyers for Ms Maxwell have said she is being used as a scapegoat for her former boyfriend and business associate's crimes. Epstein was accused of running a "vast network" of underage girls for sex, but died in a New York jail cell before he could face trial.
The image shown to the jury is one of a number picked out by prosecutors seeking to establish that Ms Maxwell and Epstein had a close relationship and were "partners in crime".
The photo was found in Epstein's Manhattan mansion, and appears to have been taken at Balmoral. The Queen and her family have been pictured sitting by what looks to be the same log cabin over the years.
The couple were known to be friends with Prince Andrew, Queen Elizabeth's third child, and it had previously been reported that he had invited them to Balmoral. At the time, Prince Andrew declined to comment.
The trial has already heard how the prince had travelled on Epstein's private jet a number of times. Prince Andrew has not been accused of any wrongdoing in the case.
Among the other images shown to the court this week were several of Maxwell and Epstein together, sometimes embracing or being intimate with each other.
Of particular note are a framed photo sitting on a table that shows the couple kissing, and a sketch of Ms Maxwell mounted on a bathroom wall.
There were also pictures of two of Ms Maxwell's accusers in various states of undress.
Ms Maxwell - who has British, American and French citizenship - faces up to 80 years in prison if convicted on counts of sex trafficking and perjury.
6 July 2019
Epstein arrest and death
Financier Jeffrey Epstein is arrested in New Jersey after returning from France on a private jet. Federal charges accuse Epstein of trafficking a “vast network” of underage girls for sex.
He kills himself in a New York jail 36 days after his arrest.
3 July 2020
Ghislaine Maxwell arrest
British socialite Ghislaine Maxwell is arrested in New Hampshire and accused of helping Epstein groom his victims.
Charges accuse her of befriending girls as young as 14 and enticing them into having sexual relations with Epstein. One alleged victim told the BBC that she “controlled the girls - she was like Madam”.
Prosecutors claim the abuse occurred in locations around the world, including Ms Maxwell’s London home.
She pleads not guilty. A judge denies her bail, calling her a flight risk.
29 March 2021
A second set of charges
Two new US federal charges of sex trafficking conspiracy and sex trafficking of a minor are filed against Ms Maxwell, adding to the six she already faced.
Prosecutors say a fourth victim has been identified. The victim was allegedly abused in 2001 when she was 14 years old. Ms Maxwell denies these charges.
23 April 2021
First court appearance
Ms Maxwell appears in court for the first time, pleading not guilty to multiple charges of sex abuse, sex-trafficking and perjury.
Her defence lawyers argue that the conditions in her Brooklyn jail are inhumane and argue that she is “being treated horribly”. She is denied bail.
29 November 2021
Ms Maxwell trial begins in New York, where she has been in jail since her arrest.
Earlier in November, a jury candidate pool of over 600 New Yorkers was whittled down to 12 jury members.