Narrative:

We were cleared for takeoff on runway xr in ZZZ. Both myself and the other pilot heard the phrase from the controller 'runway xr cleared for takeoff.' we did not hear any other instructions. We were on the zzzzz 2 departure. It states to fly heading 011 until reaching 820 feet then heading 340 or assigned by ATC. We started our turn at 820 feet and a few seconds later the controller told us to immediately turn and fly runway heading. No other problems came about from this situation. It seems like there was some miscommunication between the pilots and ATC. We were flying the appropriate procedures and did not hear ATC tell us to fly runway heading you're cleared for takeoff runway xr. Both pilots only heard 'runway xr cleared for takeoff.'

Google
 

Original NASA ASRS Text

Title: Air carrier flight crew reported a track heading deviation.

Narrative: We were cleared for takeoff on Runway XR in ZZZ. Both myself and the other pilot heard the phrase from the Controller 'Runway XR cleared for takeoff.' We did not hear any other instructions. We were on the ZZZZZ 2 departure. It states to fly heading 011 until reaching 820 feet then heading 340 or assigned by ATC. We started our turn at 820 feet and a few seconds later the Controller told us to immediately turn and fly runway heading. No other problems came about from this situation. It seems like there was some miscommunication between the pilots and ATC. We were flying the appropriate procedures and did not hear ATC tell us to fly runway heading you're cleared for takeoff Runway XR. Both pilots only heard 'Runway XR cleared for takeoff.'

Data retrieved from NASA's ASRS site and automatically converted to unabbreviated mixed upper/lowercase text. This report is for informational purposes with no guarantee of accuracy. See NASA's ASRS site for official report.