Probably the best-known is in the Petrov: 1.e4 e5 2.Nf3 Nf6, when White's commonest, and possibly best, continuation is 3.Nxe5.
White does not try to gain a material advantage by hanging onto the pawn, but rather to gain a positional advantage after Black levels material by capturing on e4.
There are other openings, however, where White's capturing on e5 only really makes sense if the idea is to hang onto the pawn.
These lines tend to be double-edged in that being a pawn up will likely be a significant advantage in any ending, and, since the capture gives White a central pawn-majority, may well be a very useful advantage in the middlegame.
However, if White proves unable to hold onto the pawn, Black will probably have at least equalised, and may well gain an advantage.
An example of this occurred in my round-five game at the Colònia de Sant Jordi U2400, which reached the following position after six moves (it arose from the Rossolimo Variation of the Sicilian, but the central structure is that of a double-e-pawn opening).
*****
*****
*****
*****
The game continued 7.Bxc6!? bxc6 8.Nxe5 0-0!?
Castling is probably Black's best move, as trying to win the pawn back with 8...Qe7 can be countered by 9.Nf3!, when either capture on e4 is a blunder that loses a piece.
There followed 9.d3 Re8 10.Nf3 d5, reaching a position that also occurred in two relatively high-level games, Ilya Smirin (2594) - Pavel Eljanov (2655), Netanya (Israel) 2019, and Sayantan Das (2459) - Adham Fawzy (2490), Guwahati (India) 2022.
Those games saw 11.Bg5 Qb6 12.Bxf6 Bxf6, after which Black is slightly better (Dragon1) or at least has the better side of equality (Stockfish17), and Black went on to win both games.
I preferred 11.e5!?, which may be a novelty.
*****
*****
*****
*****
The engines suggest 11...Nd7 or 11...Bg4, awarding Black at least equal chances.
My opponent chose 11...Ba6, and after the further moves 12.Re1 Ng4 13.Bf4 it might be thought White has successfully held onto the extra pawn on e5 as it seems to be overprotected - attacked thrice, but defended four times.
However this is illusory, as Black showed with 13...Nxe5!?, when after 14.Nxe5 f6 15.Qd2 fxe5 Black gets back the pawn and emerges with the bishop-pair and control of the centre.
*****
*****
*****
*****
Now it may be that slight improvements can be found for both sides, but as this position and the two high-level games show, White's play after grabbing the pawn is not easy.
LESSON: before spending tempi with the aim of winning a pawn in the opening, even an important central pawn, it is essential to consider all the opponent's options for counterplay. Grabbing such a pawn may be an example where the old joke applies: "Don't do it, even if it is sound!"