EXCLUSIVE: After more than a decade at Fox, Shawn Ryan is moving to Sony. The Shield creator has closed a three-year overall deal with Sony Pictures Television, which will start June 1 when his current pact with 20th Century Fox TV expires.

Ryan is coming off two back-to-back 3-year deals at 20th TV. The studio made him an offer for a new pact but Ryan also recently took meetings with other companies, and Sony and Warner Bros. TV expressed strong interest. In a three-way race over the past few days, I hear Sony TV came up with the most lucrative offer and landed the top showrunner. Ryan has a pre-existing relationship with Sony TV, which co-produced his signature series, The Shield, with Fox TV Studios. The move is part of Sony TV’s new strategy of moving away from signing non-writing executive producers and bringing in experienced showrunners. At the studio, Ryan joins a talent roster that includes such heavy hitters as Peter Tolan, Ron Moore and Jack Orman.

In pursuing Ryan, Warner Bros. was limited by the fact that it already has an A-list-heavy list of showrunners  and recently spent a lot of money on 2 big new overall deals, with Greg Berlanti and Bill Lawrence. Meanwhile, 20th TV brass, whose offer is said to have been lower than the other 2, was sad to see Ryan go despite not being able to hit a homerun with him in the 7 or so years he has been developing for the studio. Ryan shepherded one 20th TV series that reached syndication, the modest CBS hit The Unit, with his latest show, critically praised The Chicago Code, on the bubble at Fox for a second season. If the cop drama is renewed, 20th TV has Ryan’s services on the show for 2 years. “Shawn is not just a gifted creator and showrunner who has developed many fantastic projects for this studio – he is also a good friend,” 20th TV chairmen Dana Walden and Gary Newman said in a joint statement. “We will miss him at 20th and we wish him nothing but the best.”

Ryan’s relationship with Fox started in 1999 when he joined the 20th TV-produced drama Angel as a writer-producer. The next year, he moved to the cable side of the company to develop The Shield at FX, the series that would put FX on the map and propel Ryan to the top of the showrunner ranks. In 2003, after The Shield‘s second season, Ryan inked a rich overall deal with another News Corp. company, The Shield‘s co-producer Fox TV Studios, which also included a development component with 20th TV. Ryan officially moved to 20th TV in 2005 with the first of his 2 top-of-the-line pacts with the studio. At 20th TV, he recently executive produced the FX well received but short lived series Terriers and ran the second season of the Fox procedural Lie To Me.

Given his background, in his search for a new home, I hear Ryan had been looking for a studio that is a supplier to all broadcast networks and also has strong presence in cable, something both Sony and WBTV offer. Because of 20th TV’s strong ties to Fox, while the studio sells to all networks, the sister network is a priority and, between The X Factor and American Idol, its drama needs are expected to be very limited in the next couple of years.

Ryan, repped by WME, manager Larry Shuman and attorney Michael Gendler,  is the latest A-list showrunner to leave a longtime studio home this season following Berlanti and Lawrence’s moves from ABC Studios to WBTV.