For so much of their two-decade indie-rock career, The Shins focused on the future. On “Heartworms” (Aural Apothecary / Columbia), the band’s first album in five years, Shins mastermind James Mercer, also half of the forward-facing duo Broken Bells, is now mining his past.

In “Mildenhall,” he tells a sweet story about how he was a homesick American teenager when he moved to the Royal Air Force Base in England after his father was stationed there — until a classmate passed him a tape and he fell in love with music. “That’s how we get to where we are now,” he sings in the simple country-tinged ballad, adorned with synthesizer flourishes. For “Cherry Hearts,” Mercer channels mid-’80s Erasure for a synth-pop spectacular, his voice pitched up to match Andy Bell’s playful upper register.

advertisement | advertise on newsday

On “The Fear,” he addresses his battle with anxiety by laying it out plainly, in a poignant, jangly ballad where he recognizes, “This fear is a terrible drug.”

The Shins’ “Heartworms” lives up to its name, filled with tales that burrow their way into your heart long after they have stopped playing.