The law prohibits non-Thai couples and same-sex couples accessing surrogacy services, ending a booming ''rent-a-womb'' industry that made Thailand a top destination for fertility tourism.
Thailand's military rulers moved to shut down the industry after Fairfax Media revealed that Australian couple David and Wendy Farnell had abandoned Gammy, a baby with Down syndrome who was critically unwell, and taken home his healthy twin sister Pipah.
Many Thais were also shocked by another case involving a 23-year-old Japanese businessman who fathered at least 16 babies using Thai surrogates in what became known as the "baby factory" scandal.
Wanlop Tankananurak, an MP in the parliament that was hand-picked by the military, said the law aims to stop "Thai women's wombs from becoming the world's wombs".
Under the law, any Thai woman entering into a surrogacy agreement with Thais must be over 25.
"The important part is if the couple seeking surrogacy services is Thai or the couple is mixed race, they can find a Thai woman to be their surrogate providing she is over 25," Mr Wanlop said.
Violation of the law carries prison sentences of up to 10 years.
When Fairfax Media revealed Gammy's plight the military ordered a crackdown on dozens of fertility clinics across Bangkok which had hundreds of foreign clients, including many Australians.
The military allowed more than 200 Australian couples with babies that had been born or who had entered into commercial arrangements with Thai surrogate mothers to take their babies home after the Abbott government made representations to Thai authorities.
Critics say shutting down commercial surrogacy in Thailand could push the industry underground or to other countries. Thailand became a centre for surrogacy after India cracked down on its then-booming industry two years ago.
Gammy's mother Pattharamon "Koy" Janbua has obtained Australian citizenship for Gammy, who still requires regular medical treatment but is a happy 13-month-old baby with a beaming smile.
Ms Pattaramon says she has no intention of applying to relocate to Australia, but says Australian citizenship for Gammy will be good for him later in life.
Despite Mr and Mrs Farnell claiming in a media interview in Australia that they were willing to take care of Gammy, Ms Pattharamon says they have not contacted her to ask about his condition.
Emails she sent to Mr Farnell, who has convictions for child sex abuse, and Mrs Farnell went unanswered.
"I really want to know how Gammy's sister is. I want to know how much she is loved. I hope they love her as much as I love Gammy," Ms Pattharamon told the Bangkok Post, adding she believes in "twins instinct" and that one day the siblings will reunite.
But Ms Pattharamon said she believes the Farnells feel guilty about what they did. "They don't care about Gammy and they never will," she said.
The Australian Charity Hands Across the Water has bought Ms Pattharamon's family a new house with money raised after Gammy's plight was revealed. The charity is providing ongoing care for Gammy, including paying medical expenses.
Ms Pattharamon said she wants to be the one to tell Gammy the circumstances of his birth when he is old enough to understand. "No matter how I tell him, I will stress to him that he is my son.
''I carried him in my womb for nine months. I obviously have stronger bonds than his biological parents," she said.
Ms Pattharamon said she wanted her story to be a case study on the perils of unregulated surrogacy. But she said if she could "turn back in time I wouldn't change a thing".
"As bad as the situation may seem, I got to be with Gammy. He brings a true joy to my life."