Miles was born in Wimbledon, London, but lived as a young man in Ashover, Derbyshire, attending Tupton Hall School. He began acting in school productions, which he pursued mainly because it allowed him to miss classes. In an interview, Miles stated how he would spend his spare time in a now defunct record shop (Hudsons) in Chesterfield, Derbyshire while "thinking about 'finding the one'". He trained at the Guildhall School of Music and Drama. He moved into television roles in the 1990s, playing supporting roles in such series as Zorro, Soldier Soldier, Is It Legal?, The Bill, Peak Practice and Wonderful You.
In 2000, he was cast as the womanising Patrick Maitland in the comedy series Coupling, a role which he played until the series ended in 2004. He continued other television work during his tenure in Coupling, appearing in The Forsyte Saga as Montague Dartie (this was the first time Miles acted with Amanda Root) and in Prime Suspect. In 2004, Miles portrayed Charles Ryder in the BBC Radio 4 production of Brideshead Revisited. Miles was the co-lead in the BBC drama, A Thing Called Love, filmed on location in Nottingham, England.
Miles appeared in the 2005 BBC television drama Mr. Harvey Lights a Candle, playing the part of a teacher taking an unruly party of pupils on a daytrip to Salisbury Cathedral. In 2006, he appeared in the TV drama After Thomas as the father of a son with autism. He worked alongside actors such as Clive Mantle. In 2008, he appeared as the squire Sir Timothy in the British production Lark Rise to Candleford, and as Plantagenet Palliser in Radio 4 production The Pallisers. In 2009, he appeared as the head of a stock market trading firm in the BBC city-based drama Sex, the City and Me (January 2009). He played the lead in Pulse opposite Claire Foy, who he also co-starred with in The Promise in early 2011, just after also appearing in BBC 1's Zen.
Miles often works with director James McTeigue: he appeared in McTeigue's 2006 film V for Vendetta as Dascombe, in Ninja Assassin, and in Speed Racer.
On stage, he played Bolingbroke in the Old Vic's production of Richard II in 2005 alongside his father-in-law Gary Raymond, well known for Rat Patrol, El Cid and Suddenly Last Summer. Miles most recently appeared in the play The Norman Conquests as Tom in 2009. The Norman Conquests won a Tony Award during his tenure in the play for Best Revival of a Play.
In summer 2011 Miles starred as Robert in Harold Pinter's Betrayal at the Comedy Theatre in London's West End, with his wife Emma played by Kristin Scott Thomas. The love triangle was completed by Douglas Henshall as his best friend and her lover, Jerry. The revival was directed by Ian Rickson. Also in 2011 he appeared in the television film The Suspicions of Mr Whicher as Dr. Stapleton.
In 2014 Miles played Thomas Cromwell in the RSC version of Hilary Mantel's novels Wolf Hall and Bring Up the Bodies in Stratford and at the Aldwych Theatre in London. In April 2015 the RSC brought the plays to New York City.
In 2016, he appeared in "Hated in the Nation", an episode of the anthology series Black Mirror. In 2016, he also appeared in the Netflix series The Crown as Peter Townsend.
In 2017, he voiced the Time Traveller in a Big Finish Productions adaptation of The Time Machine.
Miles can play bass, drums, and guitar and is left-handed. He is married to the actress Emily Raymond, who starred in the film Love Lies Bleeding alongside Faye Dunaway; they have three children. The two also appeared together in the episode of Peak Practice, "Before The Lights Go Out" in 1999.