Ed Sheeran has been writing songs for Taylor Swift.

The 'A Team' hitmaker - who has previously penned tracks for One Direction - was asked by the country singer to work on her new album because she is a ''massive fan'' of his own music.

A source told The Sun newspaper: ''Ed and Taylor have been in the studio in LA a lot over the past few weeks working on new material.

''She's into her British music and became a massive fan of Ed before asking to work with him recently.

''There is a mutual affection between the pair.''

It has not yet been decided whether Ed's songs will be released as singles, but even just a credit on an album track will earn the 21-year-old British star around £200,000.

The source added: ''It's still to be officially decided how the material will be released but just a single credit on her album will be worth big money.

''Taylor's country sound is massive around the world.''

Earlier this month, Ed revealed he was working with a ''cool'' artist while in Los Angeles.

He tweeted: ''writing songs with a very cool artist today :) (sic)''