Kevin Federline says ''time'' healed his rift with ex-wife Britney Spears.

The 37-year-old DJ, who endured a bitter split from the 'Toxic' singer in 2006 after two years of marriage, admits co-parenting their two sons, Sean Preston, nine, and Jayden James, eight, is ''going great'' these days.

Asked about the secret to their friendship, the former backup dancer, who has been married to Victoria Prince since 2013, with whom he has daughters Jordan Kay, three, and Peyton Marie, 13 months, said: ''Time. Time heals everything.

''Now you get older, you start looking at life a different way. Kids will make you do that. Age makes you do that on its own. I enjoy my life now. I live in the moment with everything I do.''

The 'Pretty Girls' hitmaker, 33, who is dating filmmaker Charlie Ebersol, is frequently spotted attending her sons' sports games with Kevin and his family in Los Angeles.

He told Canada's etalk: ''The family is great. It's been a long, long journey, but I think where both of us are now, we both have somebody else we're happy [with]. Everything just works.''

Kevin felt sorry for Britney after hearing about her recent ankle injury onstage in Las Vegas.

He said: ''She's obviously back to work. When I heard I was like oh man rolling your ankle isn't fun, but things are good.''