BROOKLYN — With less than two weeks until New York’s presidential primary, Bernie Sanders got back to his roots on the campaign trail on Friday, revving up supporters at two rallies in his home borough, including one at his childhood home.

The Vermont senator greeted a cheering crowd Friday outside 1525 E. 26th St. in Midwood — the apartment building where he grew up, located just down the block from James Madison High School where he graduated in 1959.

Ahead of a debate scheduled for April 14 with fellow Democratic candidate Hillary Clinton (who also campaigned in the borough this week), Sanders reminded his supporters of the importance of the state’s primary — and encouraged them that he can defeat Clinton.

“We can win this primary. If we win here, we’re going to win other states. New York will help us make it to the White House,” he said.

► READ: Here's What Happened When Bernie Sanders Returned to His Childhood Home

The event, which was free and open to the public, attracted hundreds of attendees, who lined up around the block hours before the senator’s scheduled remarks.

Brooklynite Marika Rios showed her support in line with a “Bernie 2016” baseball cap. She said Sanders is her pick because he’s independent from moneyed interests.

"He's someone who's not for sale and that's a rarity in politics,” she said.

Sanders got some celebrity support in Midwood on Friday, as well. Actor Mark Ruffalo introduced the candidate, saying that Sanders' background aligns with a "New York state of mind."

"He's one of us. He grew up here and he learned how to be a politician here," he said. "We come here with dreams and we see those dreams realized here."

Enthusiasm came in many forms at the rally. One young supporter, Oscar Salazar, showed up to East 26th Street holding a sign that read “Free Bernie Hugs” and wearing a sweatshirt designed with blown up images of Sanders’ face.

“I’ve had like 400 hugs today,” he said.

Following the Midwood rally, Sanders made the trek to north Brooklyn for another public rally at WNYC Transmitter Park in Greenpoint.

There, hundreds of supporters gathered to hear Sanders speak at the waterfront park at 5 p.m. amid gusting wind and chilly temperatures.

"Fire it up, ready to Bern" crowd chants. pic.twitter.com/D12PbnD6F9 — Gwynne Hogan (@GwynneFitz) April 8, 2016

"I've been waiting for this for 45 years," said 65-year-old Ron Suarez, the organizer of a online guerrilla campaign, Groups for Bernie, who made special cut-out signs for the Greenpoint rally. "We are all Bernie."

Actress Susan Sarandon made an appearance for Sanders in Greenpoint, describing him as a "consistent moral compass."

"[He] has always voted in a way I believe in," she said of Sanders.

► READ: Go Inside the Bernie Sanders Mosh Pit at His Greenpoint Rally

The candidate himself took the stage just before 5:30 p.m., touching on issues common to his campaign: income inequality, family leave, a single-payer health care system and student debt.

"Anybody here with student debt?" he asked the crowd. "Welcome to the club. You're one of millions."

"I have not forgotten where I was born" @BernieSanders tells Greenpoint. pic.twitter.com/HFLfNYXDpq — Gwynne Hogan (@GwynneFitz) April 8, 2016

Sanders is set to appear at four rallies in three boroughs Saturday in the run-up to New York's presidential primary on April 19.

According polling data analyzed by political forecasting site FiveThirtyEight, Sander's challenger Hillary Clinton has a 97 percent chance of winning the state's primary as of Friday.