Abortion has been removed from Queensland's criminal code after laws were passed in the state's parliament following two days of debate.
Queensland women will now be able to choose to have an abortion without risking criminal prosecution, with law changes decriminalising terminations passing state parliament on Wednesday night.
The laws took two full days to debate, with dozens of MPs wanting to speak to the bill.
The laws were eventually passed 50 votes to 41, with opposition MPs Steve Minnikin, Jann Stuckey and former opposition leader Tim Nicholls voting in favour of the changes.
Labor's Linus Power abstained.
Both the government and opposition had granted their MPs a free vote ahead of the debate.
Katter's Australian Party's three MPs and One Nation MP Stephen Andrew voted against the changes, while Greens MP Michael Berkman and independent Noosa MP Sandy Bolton voted for them.
Speaking during the debate, Premier Annastacia Palaszczuk said the laws offered parliament a chance to make history.
"Because I believe, and I have always believed, a woman should be able to talk to her doctor about her own health and her own body without it being a crime," the premier said.
Emotions often ran high during the debate, with MPs from both sides sharing their personal connection to the issue.
Labor MPs Jess Pugh and Melissa McMahon shared stories of miscarriages they had suffered, in arguing for women to have autonomy over their own bodies.
While LNP member Ted Sorenson broke down in tears on Tuesday evening when detailing how he was adopted, and labelled the laws the "kill Ted bill."
Speaking against the changes, the LNP's Mark McArdle, who introduced a number of amendments to the legislation which were struck down, summed up the feelings of many LNP MPs when he said he didn't believe abortion should be in the criminal code, but also felt the proposed laws went too far.
"On the balance of the bill, I have to say I cannot support it for a fundamental number of reasons," Mr McArdle said.
Under the changes, abortion will be removed from the criminal code and made a health issue, allowing women to terminate pregnancies up to 22 weeks' gestation.
Terminations after 22 weeks will be allowed with the approval of two independent doctors.
The changes also establish safe zones around clinics and medical facilities offering the procedure to stop staff and patients being harassed by anti-abortion activists.
Before the debate began, it was revealed the LNP Pine Rivers state electorate council emailed MPs warning them they faced preselection challenges if they voted for the legislation.
It follows reports last month LNP President Gary Spence had warned his MPs they could face preselection challenges if they voted for the changes.