The crash, involving a Peugeot 206, happened on Fareham's Highlands Road in the early hours of Friday. A 23-year-old man from Fareham was pronounced dead at the scene.
A local man, 23, and a 25-year-old from Portsmouth were arrested on suspicion of causing death by dangerous driving.
Police said both had been released while inquiries continue.
The road was shut for eight hours.
Two people arrested after a fatal car crash in Hampshire have been released while investigations continue.