Rahman, whose nickname Sagar means 'sea' in Bengali, believes years of perseverance have paid off after he was handed a wildcard place to compete at the London Olympics.
Despite being crisscrossed by more than 230 rivers, swimming is a minor sport in Bangladesh and the lack of financial reward plays a major part in that.
Cricket careers can be extremely lucrative on the subcontinent while Siddikur Rahman has earned almost $150,000 on golf's Asian Tour this season.
Swimming is the poor cousin, says the 19-year-old.
"All we earn is a medal, which is sometimes not even worth 50 taka ($0.60), so it is very difficult to keep us motivated," Mahfizur told Reuters in a recent interview.
"We know we will gain very little out of it; still we keep swimming because we love it," he said at Dhaka's National Swimming Complex.
Mahfizur, who has been at Bangladesh's lone sports academy (BKSP) for more than a decade, has recently been selected by the Bangladesh Navy to become a junior commanding officer.
"When I came to BKSP in 2001, I saw everybody just wants to be a cricketer, but frankly, it has never attracted me," he said.
Mahfizur is the undisputed king of Bangladesh's freestyle swimming, winning gold medals in the 50, 100, 200, 400 and 1,500 meters in every national meet since 2007.
He struck his first gold medal at senior level in 2005 at the age of 12.
However, getting to the Olympics always seemed like a distant dream as his times had been nowhere near the top level.
He clocked 24.82 seconds in the 50 freestyle at the World Championships in Shanghai last year, far behind gold medal winner César Cielo's 21.52 seconds.
"One morning last February one of my coaches told me that I was going to swim in the Olympics. I did not believe him and went straight to the Bangladesh Olympic Association, where officials confirmed the news," he said.
"I was lost for words for a few seconds because this was unbelievably good news for me. I could not think of it despite being the best in the country for the last few years."
The International Olympic Committee granted Mahfizur a wildcard place after analysing his performance in local and domestic events.
"I always knew swimming would give me nothing but honour. And representing the country in an Olympics is the best honour for any athlete," he said. (Editing by Peter Rutherford)