From Carly Rae to Cardi B, from Kendrick to Kesha, here are the year's finest tracks.

In 2017, Carly Rae made you leap for joy while Cardi B made haters do some sole-searching; Kesha pulled off a comeback, while Kendrick put you in your place; Lil Uzi Vert broke out with that song you can't remember how to spell, while Charli XCX broke the Internet with a video you won't forget. Behold, the best songs of the year:

30. "Dear Hate," Maren Morris feat. Vince Gill

Between the bombing outside of an Ariana Grande concert in Manchester and the Route91 festival shooting in Vegas, hateful violence cast a dark shadow over the music industry in 2017. But on this duet, written in 2015 in resposnse to the Charleston church shooting and released this year after the Vegas attack, Maren Morris offers a reason to hope. "I hate to tell you," she sings, addressing the vileness, "love's gonna conquer all." What a wonderful reminder for a time that dearly needs it. —Madison Vain

29. "New Rules," Dua Lipa

1. Find a trop-house beat fresher than a piña colada. 2. Inspire Twitter memes with endlessly quotable pop-star commandments. 3. Go viral with a simple, stylish synchronized dance video. That's how you get a worldwide hit worthy of Lipa's obvious star power, and it'll be probably the first of many like it — start counting 'em now. —Nolan Feeney

28. "Have All the Songs Been Written," The Killers

Is there a band that knows how to end an album better than the Killers? From Sam's Town's "Exitlude" to Day & Age's "Goodnight, Travel Well," they've proven themselves to be masters of the final parting note. That streak continued with this sprawling lament off Wonderful Wonderful. Frontman Brandon Flowers longs for a former lover and searches, desperately, over a sea of atmospherics and bluesy guitarwork, for one final batch of lyrics "to get through to you." —M.V.

27. "Arc of Bar," Japandroids

Seven-and-a-half minutes? Multiple narrative verses? Synthesizers?! The centerpiece of the Canadian rock duo's third LP is a creative departure, sure, but it conjures sweat-soaked rock ‘n' roll catharsis as well as any of the simpler tunes in their catalog. —Eric Renner Brown

26. "Sam," Jessie Ware

Love him or hate him, Ed Sheeran does some of his best work when he's writing with other artists. And he has a particular chemistry with British soul singer Jessie Ware, whose disarmingly candid lyrics about motherhood and family here make for an instant lump in your throat. If hearing "Shape of You" ad nauseam this year was the price of admission to get this song, it was well worth it. —N.F.

25. "Jungelknugen (Four Tet Remix)," Todd Terje

How Four Tet's remix of "Jungelknugen" stacks up to Todd Terje's original remains to be seen — Terje hasn't released his version yet — but it's hard to imagine ways the remix could be improved. An intricate electro opus that builds to multiple delirious peaks, the thumping dancefloor gem contrasts well with Four Tet's comparatively sedate 2017 album. —E.R.B.

24. "New Year's Day," Taylor Swift

So Old Taylor wasn't dead, just hiding inside the revenge-seeking, man-eating dubstep supervillain character we saw on most of reputation. And after an album's worth of settling scores and exorcising her troubles, that familiar Taylor emerged for this hopeful palate-cleanser — the kind of end-credits song that stays with you long after the movie is over. —N.F.

23. "I Dare You," the xx

Comparing love to a drug high is one of the oldest tricks in the pop playbook. Yet over a pitter-patter beat that evokes a nervous heart thumping, vocalists Oliver Sim and Romy Madley Croft manage to sing about the desire and suspense of early-stage attraction in a way that's genuinely intoxicating. —N.F.

22. "Where This Flower Blooms" Tyler, the Creator feat. Frank Ocean

With Flower Boy, the polarizing rapper Tyler, the Creator finally achieved the Pharrell-style blend of electro, funk, and hip-hop to which he's long aspired. Syrupy strings and pristine pianos contrast with Tyler's gravelly flow — and then the song flips, with a quaking, Neptunes-inspired beat coming in alongside an impeccable Frank Ocean hook. —E.R.B.

21. "Thinking of a Place," The War on Drugs

No song transported listeners as thoroughly as the 11-minute centerpiece of the War on Drugs' album A Deeper Understanding. Glistening synths, sparse drums, and plaintive guitar solos create a lush instrumental landscape as frontman Adam Granduciel tells a tale of lost love set on a South Dakota stretch of the Missouri River. The tune's an adventurous blast of heartland rock that also makes good on the comparisons that've long been drawn between Granduciel and Bruce Springsteen. —E.R.B.

20. "Diane," Cam

The country newcomer scored an unlikely hit with her "Burning House" ballad last year, and that success has only emboldened her. For the first taste of her forthcoming second album, she gutsily penned a sentimental and surprisingly danceable answer to Dolly Parton's iconic "Jolene." Who knew a song about infidelity could be so heart-warming? —M.V.

19. "Boys," Charli XCX

Don't be fooled by all the shirtless video heartthrobs. Underneath the song's cotton-candy exterior and Nintendo sound effects, Charli XCX and songwriter Emily Warren deliver a surprisingly melancholy message about female friendship, digital-age isolation, and how even a revolving door of warm bodies can't fill the empty void in your heart. It's hardly empty calories. —N.F.

18. "Can I Sit Next to You," Spoon

Reliably great indie-rockers Spoon leaned into their dancefloor inclinations on this year's Hot Thoughts — and "Can I Sit Next to You" is the album's mission statement. Britt Daniel is equal parts sleazy and suave as he croons late-night invitations like "been down, but now I gotta get lifted up." —E.R.B.

17. "9 (After Coachella)," Cashmere Cat feat. MØ & SOPHIE

Kicking convention to the curb is no problem for this Norwegian producer, who dared to warp the sound of his friend's dog barking for the year's most insane bass drop. Yet a vocal assist from Danish phenomenon MØ somehow makes this bonkers cut oddly emotional. —M.V.

16. "Ascension," Gorillaz feat. Vince Staples

Prominent guests from Mavis Staples to Pusha T line the credits of Gorillaz' new album, but the young rapper outshines them all, spinning an apocalyptic tale of police brutality and lynching over Damon Albarn's disconcertingly peppy electro-pop groove. —E.R.B.

15. "Cool Your Heart," Dirty Projectors feat. DAWN

Dirty Projectors mastermind Dave Longstreth spent the years since the group's last album in 2012 working with the likes of Kanye West and Solange — and on "Cool Your Heart," co-written with the latter, his forward-thinking fusion of chopped-and-screwed electro and blissful R&B shines. —E.R.B.

14. "Passionfruit," Drake

The Toronto MC released a wealth of music in 2017 — his More Life "playlist" pushed the limits of patience with 22 songs — but this tropical cut still finds him at his Drake-iest: With an infectious, sway-inducing beat and a wistful rap about losing hope in what once seemed like a promising long-distance relationship, you'll be moved to buy him the next round. —M.V.

13. "Don't Kill My Vibe," Sigrid

The Norwegian newcomer's debut is so much more than a middle finger to a rude producer she met in a songwriting session gone awry. It's a bite-sized bildungsroman about the potent, life-changing combination of fear and excitement. "I throw myself from heights that used to scare me," Sigrid sings during the song's eureka moment. Go ahead and take the plunge with her. —N.F.

12. "XO TOUR Llif3," Lil Uzi Vert

Suicide, heartbreak, and alienation gurgle beneath the twinkling trap beat of the 23-year-old Philly rapper's masterful single. Uzi's clear-eyed chronicle of depression immediately resonated with disaffected teens and young adults; chart-topping hip-hop rarely gets this intimate. —E.R.B.

11. "Want You Back," Haim

Tongue-twisting harmonies, karaoke-ready key changes, a funky slap bass straight out of the '80s, pitched-up vocals straight out of 2017 — the sister act's slightly sappy, time-traveling wonder is so kinetic, you just might burst into a dance routine while walking down the street. —N.F.

10. "Bad Liar," Selena Gomez

She's trying trying trying to get a guy out of her head and all the grown-up places it wanders; you'll be trying trying trying to get this delightfully weird snack of a song out of yours, too, thanks to its goofy AP History lyrics ("Just like the battle of Troy/There's nothing subtle here") and Gomez's trademark sexy-whisper singing. —N.F.

9. "White Man's World," Jason Isbell and the 400 Unit

Much breath has been wasted debating what genre Jason Isbell falls into. Country? Americana? Rock? Who cares — what matters is his fearless, searing songwriting. Before launching into a fiery guitar solo, he examines all the ways he benefits from a society that isn't so kind to people who don't look like him. Now that's how you check your privilege. —M.V.

8. "Bodak Yellow," Cardi B

With its stuttering drums and sinister synths, the Bronx breakout's chart-conquering single sounded like plenty of commercial rap in 2017. Yet Cardi's unrelenting flow, barreling charisma, and unforgettable lines ("These is red bottoms/these is bloody shoes") elevated the cut above its competition — and helped her become the first solo female rapper to top the Hot 100 in nearly two decades. —E.R.B.

7. "Everything Now," Arcade Fire

The Canadian rockers have long favored grandiose themes, from suburban life to death and grieving. This standout from their polarizing fifth LP is no different, indicting media saturation and our pepertual insatiability. "Stop pretending you've got/Everything now!" frontman Win Butler rails, with enough zeal to make you look up from your phone. —M.V.

6. "Pa'lante," Hurray for the Riff Raff

Alynda Lee Segarra's best song as Hurray for the Riff Raff takes on ruthless imperialism and callous immigration policies. But the multi-part song, which grows from a somber piano ballad to gripping rallying cry, draws hopeful conclusions: At its climax, Segarra nods to her Puerto Rican heritage by belting "pa'lante" — "onward." —E.R.B.

5. "Slide," Calvin Harris feat. Frank Ocean & Migos

Fronted by the elusive Frank Ocean with a breezy assist from guest-spot MVPs Migos, the U.K. club don's shimmering anthem bounced from roller-disco squiggle to deep-cut Picasso references — a blithe beach jam so incandescent it could light up a basement cubicle in Fargo. —Leah Greenblatt

4. "Cut to the Feeling," Carly Rae Jepsen

Nobody in pop does songs about navigating sexual tension and making the first move better than Carly Rae — and this E•MO•TION-era gem, left off both her 2015 LP and its b-sides collection before finding a home in the movie Leap!, reaches the same giddy heights of "Call Me Maybe." —N.F.

3. "(No One Knows Me) Like the Piano," Sampha

Music is forever finding new ways to express love and loss, as the British soul singer gorgeously reminded us on this spare, tender elegy — a heart-rending tribute to both the instrument and the strength of the woman (his late mother, Binty) who supplied it. —L.G.

2. "Praying," Kesha

Some victory anthems lose their spine-tingling powers after too many listens, but not Kesha's. Between its gospel-choir kick and the high note that launched a thousand YouTube reaction videos — not to mention its ripped-from-the-headlines story of trauma and triumph — "Praying" is guaranteed to give goosebumps for years to come. —N.F.

1. "HUMBLE.," Kendrick Lamar