Both former No. 1 players advanced to the second round at Roland Garros, playing through rain and rain delays.
Djokovic beat Joao Sousa of Portugal 6-1, 6-2, 6-4 despite being broken three times, including while serving for the match for the first time.
The second-seeded Serb was leading 4-1 when rain halted play on Court Philippe Chatrier, but it restarted about an hour later.
In the second set, a short shower stopped play for only a few minutes. Djokovic, wearing a white rain jacket, used the time to entertain the crowd by chatting with a ball boy and letting the youngster sit alongside him on the bench.
At one point, Djokovic grabbed the umbrella out of the ball boy's hand and in return gave him a racket. Then Djokovic handed him a bottle of Perrier, and the two clinked bottles before taking a sip.
Djokovic can complete a career Grand Slam by winning the French Open.
Sharapova, the 2012 champion, was first on court in the main stadium and needed little more than an hour to beat Ksenia Pervak 6-1, 6-2.
"It's always nice to get out there on a day like this. It's good to play first match, as you know," Sharapova said. "Hopefully you'll be able to finish the match today with the weather conditions being as they are. It's always nice to get through."
Sharapova broke Pervak five times and finished with 17 winners, while Pervak had only four.
Sharapova, seeded seventh at the French Open, completed a career Grand Slam at Roland Garros two years ago. She then lost to Serena Williams in the 2013 final.
Up next in Paris will be Tsvetana Pironkova of Bulgaria in the second round. But she could face Williams in the quarterfinals.
"It's tough to think about that match down the line where you have to compete in three matches before that," Sharapova said. "Obviously it's a match that many people always look forward to when we play against each other."
Monday's match started about 1 hour, 20 minutes late because of the wet weather. The forecast calls for more rain Monday, and for the rest of the week.
Australian Open runner-up Dominika Cibulkova of Slovakia also advanced, beating Virginie Razzano of France 7-5, 6-0.
Other winners include No. 12 Flavia Pennetta of Italy, No. 16 Sabine Lisicki of Germany and No. 18 Eugenie Bouchard of Canada.
On the men's side, ninth-seeded Kei Nishikori was knocked out at the first step, losing to Martin Klizan of Slovakia 7-6 (4), 6-1, 6-2.
Nishikori won his first clay-court title in Barcelona last month. He then reached the final in Madrid but had to retire with a back injury against Rafael Nadal.
Nishikori, the highest-ranked Japanese man in history, is No. 10 in the world, one spot lower than his career high.
No. 25 Marin Cilic of Croatia and No. 29 Gilles Simon of France advanced.
Later Monday, eight-time champion Nadal and Australian Open champion Stan Wawrinka were scheduled to play — weather permitting.