He was appointed organist at Westminster Abbey in 1668 at age 19. In 1674 he became a Gentleman of the Chapel and the same year succeeded Pelham Humfrey as Master of the Children.
This position he held for the rest of his life. Among his pupils were William Croft and Henry Purcell. In 1676 he was made one of the Chapel Royal organists; the following year he received the D.Mus. from the Dean of Canterbury.
During the next years he composed many of his best-known works, including most of the anthems with string accompaniment and the masque Venus and Adonis.He was appointed choirmaster at St. Paul's Cathedral in 1687. In 1695 he was named royal instrument tuner; finally in 1699 or 1700 he became the official Chapel Royal composer, the first to hold such a post.
He composed eleven services (edited in William Boyce, Cathedral Music, 3 vols., London, 1760-73); some 115 anthems (eleven are in Boyce's collection); ten Latin church works; Venus and Adonis;thirty-six known odes (including several for St. Cecilia's Day; "Great Sir, the joy of all our hearts"; "Ode on the Death of Mr. Henry Purcell"); many songs and catches; pieces for string ensemble; organ; harpsichord works.