The album's opener, "Sunday Bloody Sunday", an ardent protest song, stems from a guitar riff and lyric written by The Edge
in 1982. Following an argument with his girlfriend, and a period of
doubt in his own song-writing abilities, The Edge — "feeling
depressed... channeled [his] fear and frustration and self-loathing into
a piece of music." Early versions of the song opened with the line,
"Don't talk to me about the rights of the IRA, UDA"
After Bono had reworked the lyrics, the band recorded the song at Windmill Lane Studios in Dublin. The opening drum pattern soon developed into the song's hook. A local violinist, Steve Wickham, approached The Edge one morning at a bus stop
and asked if U2 had any need for a violin on their next album. In the
studio for only half a day, Wickham's electric violin became the final
instrumental contribution to the song.
During the sessions for "Sunday Bloody Sunday", producer Steve Lillywhite encouraged drummer Larry Mullen, Jr. to use a click track, but Mullen was firmly against the idea. A chance meeting with Andy Newmark (of Sly & the Family Stone) — a drummer who used a click track religiously — changed Mullen's mind. Mullen used the click track to stay in time for other songs on the album.Mullen said of the album in a 1983 interview, "I think the drumming has
always been pretty simple, I don't think it needs to be flashy. For War
I use a click track, something I haven't used before, it's a way of
keeping time in my headphones. When I listened to the music in time with
the click track I knew I had to bring it down to the real basics.
Hopefully for the next LP it will be more complicated, I'll move on. I
think of it as a musical progression for myself because I learned a lot
recording this album, just about my own style and that's what I wanted
to do. I think there is a definite style on War where there isn't on the previous albums."
The studio version of "40" was recorded right at the end of the recording sessions for War. Bassist Adam Clayton had already left the studio, and the three remaining band members decided they didn't have a good song to end the album. Bono, The Edge, and Mullen Jr. quickly recorded the song with The Edge switching off to both the electric and bass guitar. Bono called the song "40" as he based the lyrics on Psalm 40. In live versions of the song, The Edge and Clayton switch roles, as Clayton plays guitar and Edge plays the bass.