Drogba had been tipped to make the move to the Far East since he announced last month he was leaving Chelsea after scoring the decisive penalty for the London club in their Champions League final shootout victory over Bayern Munich.
The 34-year-old would join up with his new team-mates in July once his contract with Chelsea expired on June 30, Shanghai said in a statement on Wednesday.
"I have studied all the offers I had during the past few weeks and I have the feeling that going to Shanghai is the right direction for me now," Drogba said on his website.
"I am looking forward to that challenge, to discover a new culture and I am very enthusiastic about the development of the Chinese football league."
Shanghai will be hoping the Ivorian, nicknamed 'The Beast' in China, can make an instant impact and help the side arrest a dismal start to the campaign which has left them sitting 12th in the 16-team league despite heavy investment.
After forking out huge sums for former France international Jean Tigana they sacked the manager after a poor start with Anelka taking over coaching duties only to be reluctantly replaced by former Argentine boss Sergio Batista.
No financial details of the two-and-a-half-year contract were revealed by Drogba, or the club, but widespread media reports said the Ivory Coast striker would receive in the region of $300,000 a week.
Whatever the cost, his signing is another coup for the reinvigorated Chinese Super League.
After years of negative headlines brought by match-fixing scandals which hit its credibility and led to jail terms for former Chinese football chiefs, signings of high profile names like Drogba are now drawing attention for all the right reasons.
Ambitious Shanghai owner Zhu Jun posted a photo on his microblog site of Drogba and the club director Zhou Jun posing with a Shenhua shirt, with the caption "Our warmest welcome," shortly after the powerful forward announced the move.
"The twin guns of Chelsea will now don the jerseys of Shanghai Shenhua to do battle at Hongkou Stadium," Shanghai said on their website.
"This scene would perhaps only be played out on a fantasy football game. But today, this dream has become a reality. With hard work and determination, a dream will always become reality one day."
Drogba's arrival is the latest in a long list of high-profile names who have made the move to China in recent months. Italian World Cup winning coach Marcello Lippi leads a Guangzhou Evergrande side packed full of skilful South American talent.
But Drogba, who scored 157 times in 341 appearances for Chelsea making him the club's fourth all-time leading scorer, is perhaps the biggest catch.
Having left Olympique Marseille to join Chelsea in 2004 he won everything in England and his strength and speed made him a handful for world class defenders to deal with.
He spearheaded Chelsea's Champions League titl
Get the best features, fun and footballing frolics straight to your inbox every week.
Thank you for signing up to Four Four Two. You will receive a verification email shortly.
There was a problem. Please refresh the page and try again.