Anne, the second daughter of James, the Duke of York and Anne, the Duchess of York, was born at 11:39 p.m. on 6 February 1665 at St James's Palace, London. She was baptised into the Anglican faith at the Chapel Royal at St James's. Her older sister, Mary, was one of her godparents, along with Archbishop of Canterbury Gilbert Sheldon and Anne Scott, Duchess of Monmouth.
According to the wikipedia summary:
As a child, Anne suffered from an eye condition, which manifested as excessive watering known as "defluxion". For medical treatment, she was sent to France, where she lived with her paternal grandmother, Queen Dowager Henrietta Maria, at the Château de Colombes near Paris. Following her grandmother's death in 1669, Anne lived with an aunt, Henriette Anne, Duchess of Orléans. On the sudden death of her aunt in 1670, Anne returned to England. Her mother died the following year. As was traditional in the royal family, Anne and her sister were brought up separated from their father in their own establishment at Richmond, London. On the instructions of Charles II, they were raised as Protestants. They were placed in the care of Colonel Edward and Lady Frances Villiers and their education was focused on the teachings of the Anglican church.
Around 1671, Anne first made the acquaintance of Sarah Jennings, who later became her close friend and one of her most influential advisors. Jennings married John Churchill (the future Duke of Marlborough) in about 1678. He was the brother of the Duke of York's mistress, Arabella Churchill, and was to be Anne's most important general.
In 1673, the Duke of York's conversion to Roman Catholicism became public (Anne's mother had also become a Catholic before her death). He married a Catholic princess, Mary of Modena, who was only six and half years older than Anne. Charles II had no surviving legitimate children, and so the Duke of York was next in the line of succession, followed by his two surviving daughters from his first marriage, Mary and Anne. Over the next ten years, the new Duchess of York had ten children, but all were either stillborn or died in infancy, leaving Mary and Anne second and third in the line of succession after their father.
Mary Beatrice of Modena and Queen Anne of Great Britain thus had a similar history of pregnancy. Anne married Protestant Prince George of Denmark brother of King Christian V of Denmark in 1683. Anne was pregnant seventeen (17) times: six stillborn babies, six miscarriages, and five live births. The only child to survive infancy was William, Duke of Gloucester, and he died at age 11.
The Official Website of The British Monarchy summarizes her reign as queen here.