The largest regular-season crowd in Nationals history witnessed Harper's impressive performance, along with Strasburg throwing seven shutout innings, scattering three hits.
"For the first Opening Day for a lot of guys out there on that field, I thought we handled ourselves well," Marlins manager Mike Redmond said. "I thought we played a great game. They got two big hits, and that was the difference."
The upstart Marlins, with nine players experiencing their first big league Opening Day, got a taste of what a playoff environment felt like. They witnessed everything from player introductions to the unveiling of Washington's 2012 National League East title banner.
"This is good, right out of the chute, get it in," said Juan Pierre, who had one of Miami's three hits. "Them raising the banner in front of 45,000, and a guy like Strasburg on the mound. It won't get too much more intense throughout the season.
"I think the guys will learn from it. Learn it's just one game. We've got 161 more to go. We don't need to push the panic button just yet. But the guys just want to do well, especially the young guys. We'll be all right."
Celebrating their 21st season opener, the Marlins fell to 10-11 on Opening Day. The shutout was the first since 2006, at Houston, which turned into a 1-0 loss.
Overall, Nolasco was impressive over six innings, striking out five, while allowing two hits. But both were homers.
"The kid's locked in," Nolasco said of Harper. "He had a good spring. I didn't make the best pitches to him, and he didn't miss them. That's what good hitters do. Obviously, with the spring he's had, he's seeing the ball really well, and he's not missing those mistakes."
Harper is the first defending Rookie of the Year Award winner to belt two homers on Opening Day the following season since Ryan Howard of the Phillies on April 3, 2006, and he became the youngest player to hit two homers on Opening Day.
The distinction of the Marlins' first hit of the season went to Pierre, who singled to center on Strasburg's second pitch.
For the Marlins, Pierre was their only baserunner through six innings. And the veteran was stranded at third in the first, in which Miami's only scoring chance was erased by a terrific defensive play by third baseman Ryan Zimmerman, who made a diving stop on Placido Polanco's sharp grounder.
But the first run allowed came in the bottom of the first when Harper connected on a home run, extending his hitting streak to 10 games, dating back to last September.
Strasburg settled after Pierre's leadoff single, retiring 19 straight, before Giancarlo Stanton's double with one out in the seventh.
In both innings the Marlins had hits off Strasburg, they stranded runners at third base. Trailing by two runs in the seventh, Miami threatened after Stanton's double and Polanco's infield single. With runners on the corners, Rob Brantly lined out to Harper in short left.
Stanton tagged and took a few steps towards the plate before slamming on the brakes as Harper made a strong throw home. Polanco, meanwhile, got caught in a rundown between first and second. During the rundown, Stanton raced home, but was tossed out trying to score on a 7-2-3-4-2 double play.
"[Polanco] thought Stanton was going to go," Redmond said. "He faked halfway down the line, and he stopped. I think that's what happened, he took off because he thought he was going to go. Stanton would have been out anyway.
"Plays like that get magnified when we only get three hits. That's the difference. We had a couple of chances, if we scored in the first, maybe we could have switched the momentum to our side early, and who knows what would have happened."
Like Strasburg, Nolasco settled into a groove after he surrendered the first-inning blast. The Miami right-hander didn't allow another hit until the fourth inning, and again it was Harper who did more damage. With the count full, the 20-year-old sensation connected for the second time. This time, turning on a slider. Harper's first homer came on a curveball.
"He's just got a great stroke and a great approach, and he's a smart hitter," Nationals manager Davey Johnson said. "I'm sure he looked at the film and had a pretty good idea of how [Nolasco] likes to set up his fastball and how he likes to pitch. He was talking about pitchers last year, veteran pitchers, about what they do in situations with men on base, what they start hitters off with. So he's not just a good talent, he pays attention."
The third time Harper was up, he faked to bunt on a pitch, and eventually lifted a fly ball out to left field.
"The guy can run," Nolasco said when asked about the gesture to bunt. "He's going to do whatever he can to get on base. He's a complete player. If he wants to lay it down, lay it down."
Even though the result didn't go the Marlins' way, the players enjoyed the energy in the ballpark.
"It's definitely exciting," Nolasco said. "Although we're on the visiting team, you appreciate sellout crowds and the way they support their home team here. I think it's awesome. They've got something really good going here. It's fun to be out there."