Shawn Mendes has shared his new song 'Heartbeat' from the motion picture 'Lyle, Lyle, Crocodile'.

The 24-year-old pop star voices the titular character in Will Speck and Josh Gordon's big-screen adaptation of the classic children's tale, and he's also recorded a number of tracks for the soundtrack.

The first is 'Heartbeat', out now, and the other songs are 'Top of the World', 'Carried Away', 'Take a Look at Us Now', a duet with co-star Javier Bardem, and 'Rip Up the Recipe' with Constance Wu.

The 'Wonder' hitmaker previously admitted it was a challenge making sure he nailed the emotion behind each lyric for the character.

He explained: “The hardest part though is that when you are singing for a film instead of your own album, you really have to ace the nuances of the emotion behind every lyric and every note and match it to how the character will be portraying it on screen. “That was a learning experience.”

The film and soundtrack arrive on October 7.

Last month, the 'In My Blood's singer announced he was postponing his world tour to focus on his mental health after hitting "breaking point", and he is trying to "take it easy" during his break while relishing the opportunities he's not been able to embrace over the last few years.

He said: "I'm taking a lot of time doing therapy, taking it easy man, spending time with family that I haven't been able to.

"I think for me it's just been about spending times doing things I haven't really done over the last few years, having dinner with friends and stuff."

The 'Stitches' hitmaker previously explained he finds it "difficult" being on the road so needed to take time off.

He wrote on Instagram: "It breaks my heart to have to say this, but unfortunately I’m going to have to postpone the next three weeks of shows through Uncasville, CT until further notice.

"I’ve been touring since I was 15 and to be honest it’s always been difficult to be on the road away from friends and family.

“After a few years off the road, I felt like I was ready to dive back in, but that decision was premature and unfortunately the toll of the road and the pressure has caught up to me and I’ve hit a breaking point.

“After speaking with my team and health professionals, I need to take some time to heal and take care of myself and my mental health, first and foremost.

“As soon as there are more updates I promise I will let you know. Love you guys.”

Back in April, Shawn shared his issues in an open letter to fans, where he admitted struggling to be his true self in the public eye.