It's been a few weeks since Landry Fields and Jeremy Lin's pregame handshake went viral on YouTube. But it's worth digging deeper into the ritual because it says so much about the two players who invented it and the tight bond they've forged.

Fields and Lin are fellow Californians who met years before both landed in the Knicks' starting backcourt. But it is something much bigger than geographic proximity that has made them fast friends in this whirlwind of a Knicks season.

The two share the same interests, humor and value system, which is exactly what they were trying to project when they came up with the handshake before Lin's first start against Utah on Feb. 6.

"We're religious, geeky athletes," Fields said this past week as the team prepared for Sunday's game in Boston. "If you had to boil it down to three words, that's the handshake."

It's hard to understate the role Field's friendship has played in both Lin's emergence and his ability to remain sane amid the Lin-sanity. At the same time, Lin has played a key role in the resurgence of Fields, who has flourished in the up-tempo offense Lin runs so well.

"They have a great chemistry both on and off the court," center Tyson Chandler said. "They're two young players who are going to be able to grow together, and building a friendship off the court always helps on the court. Everybody goes through tough times in this sport, and when you have someone that you can go to that you really trust, it helps."

Long before Fields offered Lin the now-famous couch he slept on the night before bursting off the bench and into stardom with a 25-point game against the Nets on Feb. 4, the two were getting to know each other on the court in summer games at Stanford.

Subscribe to Newsday’s sports newsletter

Receive stories, photos and videos about your favorite New York teams plus national sports news and events.

Lin grew up in Palo Alto, Calif., attending a high school just across the boulevard from Stanford. His dream was to play college basketball for the Cardinal, but then-coach Trent Johnson, like every other Division I coach, did not offer him a scholarship. Instead, Johnson offered a spot in his backcourt to Fields, then a star at Los Alamitos High in Southern California. Lin, who didn't get any Division I scholarship offers, headed east to play for Harvard in the Ivy League.

When Lin returned home for the summer after his freshman year at Harvard, he started playing pickup games at Stanford. "They always needed extra guys to play," Lin said. "Landry was kind of the guy I would always contact."

Fields said the two hung out a couple of times together when Lin visited Southern California, but it wasn't until Lin joined the team this season that they became fast friends.

Fields, the Knicks' second-round pick in 2010, was tabbed as a rising young star when he surprisingly won a starting job as a rookie last season. But he struggled in the second half of the season after Carmelo Anthony joined the team, then all but disappeared in the playoffs.

When Lin signed with the Knicks and joined the team in the first week this season, it was Fields who took him out to dinner. The two quickly found out that they had a lot in common.

"I think it's just the kind of personalities we have," Fields said. "We kind of mesh together. There's no ego involved. If he needs to tell me something, he just tells me something. There's no ego involved."

One of the things the two share is the same offbeat sense of humor, which was on display at the All-Star Game when Fields posed as a reporter and asked Lin the first question of his news conference. (The two planned the gag while walking to the news conference.) Fields also tweeted a picture of his couch and announced, "Let the bidding begin."

But things aren't always fun and games between the two. When the Knicks briefly sent Lin to the Development League (he had 28 points, 12 assists and 11 rebounds Jan. 20 in his only game), the guard talked to Fields about it. "He was kind of upset about it when he told me, because it's tough to go down there," Fields said. "But I think it honestly helped him out. He got a pretty good perspective on it."

It wasn't long before the world got a new perspective on Lin. On Jan. 27 in Miami, the two players prayed together in a pregame chapel that Lin wouldn't be cut from the team. Eight days later, Lin-sanity was born as Lin came off the bench to score 25 points against the Nets.

It was after that game, when Lin was told he would start against Utah at Madison Square Garden on Feb. 6, that the two came up with their pregame ritual.