The struggle with her teenage brother over the throne of Egypt was not going as well as Cleopatra VII had hoped. In 49 B.C., Pharaoh Ptolemy XIII—also her husband and, by the terms of their father's will, her co-ruler—had driven his sister from the palace at Alexandria after Cleopatra attempted to make herself the sole sovereign. The queen, then in her early twenties, fled to Syria and returned with a mercenary army, setting up camp just outside the capital.
Meanwhile, pursuing a military rival who had fled to Egypt, the Roman general Julius Caesar arrived at Alexandria in the summer of 48 B.C., and found himself drawn into the Egyptian family feud. For decades Egypt had been a subservient ally to Rome, and preserving the stability of the Nile Valley, with its great agricultural wealth, was in Rome's economic interest. Caesar took up residence at Alexandria's royal palace and summoned the warring siblings for a peace conference, which he planned to arbitrate. But Ptolemy XIII's forces barred the return of the king's sister to Alexandria. Aware that Caesar's diplomatic intervention could help her regain the throne, Cleopatra hatched a scheme to sneak herself into the palace for an audience with Caesar. She persuaded her servant Apollodoros to wrap her in a carpet (or, according to some sources, a sack used for storing bedclothes), which he then presented to the 52-year old Roman.